⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 xti.h

📁 This a separate release of the OpenSS7 X/Open XTI/TLI library, TLI modules (timod, tirdwr) and the I
💻 H
📖 第 1 页 / 共 2 页
字号:
 *  Format of the address and options arguments of bind. */struct t_bind {	struct netbuf addr;	unsigned int qlen;};/*  * Options management structure. */struct t_optmgmt {	struct netbuf opt;	t_scalar_t flags;};/*  * Disconnection structure. */struct t_discon {	struct netbuf udata;		/* user data */	int reason;			/* reason code */	int sequence;			/* sequence number */};/*  * Call structure. */struct t_call {	struct netbuf addr;		/* address */	struct netbuf opt;		/* options */	struct netbuf udata;		/* user data */	int sequence;			/* sequence number */};/*  * Datagram structure. */struct t_unitdata {	struct netbuf addr;		/* address */	struct netbuf opt;		/* options */	struct netbuf udata;		/* user data */};/*  * Unitdata error structure. */struct t_uderr {	struct netbuf addr;		/* address */	struct netbuf opt;		/* options */	t_scalar_t error;		/* error code */};/*  * Leaf status structure. */struct t_leaf_status {	int leafid;			/* leaf whose address has changed */	int status;			/* status: T_CONNECT or T_DISCONNECT */	int reason;			/* disconnect reason */};#define t_leaf_status t_leaf_status#define T_LEAF_NOCHANGE		0#define T_LEAF_CONNECTED	1#define T_LEAF_DISCONNECTED	2#ifndef __KERNEL__/*  *  XTI LIBRARY FUNCTIONS *//* XTI Library Function: t_accept - accept a connection request */extern int t_accept __P((int, int, const struct t_call *));/* XTI Library Function: t_addleaf - add a leaf to point to multipoint connection */extern int t_addleaf __P((int, int, struct netbuf *));/* XTI Library Function: t_alloc - allocate a library structure */extern char *t_alloc __P((int, int, int));/* XTI Library Function: t_bind - bind an address to a transport endpoint */extern int t_bind __P((int, const struct t_bind *, struct t_bind *));/* XTI Library Function: t_close - close a transport endpoint */extern int t_close __P((int));/* XTI Library Function: t_connect - establish a connection */extern int t_connect __P((int, const struct t_call *, struct t_call *));/* XTI Library Function: t_error - produce error message */extern int t_error __P((const char *));/* XTI Library Function: t_free - free a library structure */extern int t_free __P((void *, int));/* XTI Library Function: t_getinfo - get protocol-specific service information */extern int t_getinfo __P((int, struct t_info *));/* XTI Library Function: t_getprotaddr - get protocol addresses */extern int t_getprotaddr __P((int, struct t_bind *, struct t_bind *));/* XTI Library Function: t_getstate - get the current state */extern int t_getstate __P((int));/* XTI Library Function: t_listen - listen for a connection indication */extern int t_listen __P((int, struct t_call *));/* XTI Library Function: t_look - look at current event on a transport endpoint */extern int t_look __P((int));/* XTI Library Function: t_open - establish a transport endpoint */extern int t_open __P((const char *, int, struct t_info *));/* XTI Library Function: t_optmgmt - manage options for a transport endpoint */extern int t_optmgmt __P((int, const struct t_optmgmt *, struct t_optmgmt *));/* XTI Library Function: t_rcv - receive data or expedited data on a connection */extern int t_rcv __P((int, char *, unsigned int, int *));/* XTI Library Function: t_rcvconnect - receive the confirmation from a connection request */extern int t_rcvconnect __P((int, struct t_call *));/* XTI Library Function: t_rcvdis - retrieve information from disconnect */extern int t_rcvdis __P((int, struct t_discon *));/* XTI Library Function: t_rcvleafchange - acknowledge receipt of a leaf change indication */extern int t_rcvleafchange __P((int, struct t_leaf_status *));/* XTI Library Function: t_rcvrel - acknowledge receipt of an orderly release indication */extern int t_rcvrel __P((int));/* XTI Library Function: t_rcvreldata - receive an orderly release indication or confirmation   containing user data */extern int t_rcvreldata __P((int, struct t_discon *));/* XTI Library Function: t_rcvudata - receive a data unit */extern int t_rcvudata __P((int, struct t_unitdata *, int *));/* XTI Library Function: t_rcvuderr - receive a unit data error indication */extern int t_rcvuderr __P((int, struct t_uderr *));/* XTI Library Function: t_rcvv - receive data or expedited data sent over a connection and put the    data into one or more noncontiguous buffers */extern int t_rcvv __P((int, struct t_iovec *, unsigned int, int *));/* XTI Library Function: t_rcvvudata - receive a data unit into one or more noncontiguous buffers */extern int t_rcvvudata __P((int, struct t_unitdata *, struct t_iovec *, unsigned int, int *));/* XTI Library Function: t_removeleaf - remove a leaf from a point to multipoint connection */extern int t_removeleaf __P((int, int, int));/* XTI Library Function: t_snd - send data or expedited data over a connection */extern int t_snd __P((int, char *, unsigned int, int));/* XTI Library Function: t_snddis - send user-initiated disconnect request */extern int t_snddis __P((int, const struct t_call *));/* XTI Library Function: t_sndrel - initiate an orderly release */extern int t_sndrel __P((int));/* XTI Library Function: t_sndreldata - initiate or respond to an orderly release with user data */extern int t_sndreldata __P((int, struct t_discon *));/* XTI Library Function: t_sndudata - send a data unit */extern int t_sndudata __P((int, const struct t_unitdata *));/* XTI Library Function: t_sndv - send data or expedited data, from one or more noncontiguous   buffers, on a connection */extern int t_sndv __P((int, const struct t_iovec *, unsigned int, int));/* XTI Library Function: t_sndvudata - send a data unit from one or more non-contiguous buffers */extern int t_sndvudata __P((int, struct t_unitdata *, struct t_iovec *, unsigned int));/* XTI Library Function: t_strerror - generate error message string */extern const char *t_strerror __P((int));/* XTI Library Function: t_sync - synchronise transport library */extern int t_sync __P((int));/* XTI Library Function: t_sysconf - get configurable XTI variables */extern int t_sysconf __P((int));/* XTI Library Function: t_unbind - disable a transport endpoint */extern int t_unbind __P((int));#endif	/* __KERNEL__ *//*  * The following are the events returned from t_look(). */#define T_LISTEN	0x0001	/* connection indication received */#define T_CONNECT	0x0002	/* connection confirmation received */#define T_DATA		0x0004	/* normal data received */#define T_EXDATA	0x0008	/* expedited data received */#define T_DISCONNECT	0x0010	/* disconnection received */#define T_UDERR		0x0040	/* datagram error indication */#define T_ORDREL	0x0080	/* orderly release indication */#define T_GODATA	0x0100	/* sending normal data is again possible */#define T_GOEXDATA	0x0200	/* sending expedited data is again possible */#define T_LEAFCHANGE	0x0400	/* status of a leaf has changed */#define T_EVENTS	0x0800#define T_ERROR		(~0)#if defined(_XOPEN_SOURCE)/*  * The following are structure types used when dynamically allocating the * above structures via t_alloc(). */#define T_BIND		1	/* allocate t_bind structure */#define T_OPTMGMT	2	/* allocate t_optmgmt structure */#define T_CALL		3	/* allocate t_call structure */#define T_DIS		4	/* allocate t_discon structure */#define T_UNITDATA	5	/* allocate t_unitdata structure */#define T_UDERROR	6	/* allocate t_uderr structure */#define T_INFO		7	/* allocate t_info structure */#else#define T_BIND_STR	1	/* allocate t_bind structure */#define T_OPTMGMT_STR	2	/* allocate t_optmgmt structure */#define T_CALL_STR	3	/* allocate t_call structure */#define T_DIS_STR	4	/* allocate t_discon structure */#define T_UNITDATA_STR	5	/* allocate t_unitdata structure */#define T_UDERROR_STR	6	/* allocate t_uderr structure */#define T_INFO_STR	7	/* allocate t_info structure */#endif/*  * The following bits specify which fields of the above structures should be * allocated by t_alloc(). */#define T_ADDR		0x0001	/* address */#define T_OPT		0x0002	/* options */#define T_UDATA		0x0004	/* user data */#define T_ALL		0xffff	/* all the above fields supported *//*  * The following are the states for the user. */#define T_UNINIT	0	/* unitialized state */#define T_UNBND		1	/* unbound */#define T_IDLE		2	/* idle */#define T_OUTCON	3	/* outgoing connection pending */#define T_INCON		4	/* incoming connection pending */#define T_DATAXFER	5	/* data transfer */#define T_OUTREL	6	/* outgoing release pending */#define T_INREL		7	/* incoming release pending *//*  * General purpose defines. */#define T_YES		1#define T_NO		0#define T_UNUSED	(-1)#define T_NULL		0#define T_ABSREQ	0x8000#if defined(_XOPEN_SOURCE)#define T_INFINITE	(-1)	/* The corresponding size is unbounded. */#define T_INVALID	(-2)	/* The corresponding element is invalid. */#endif/*  *  Definitions for t_sysconf */#ifndef _SC_T_IOV_MAX#define _SC_T_IOV_MAX	1#endif#endif				/* !defined _SYS_XTI_H */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -