/*
    AUTOMATICALLY GENERATED BY tspec 2.10
    API SUBSET: unix95:sys/socket.h (VERSION 2.7)
*/

#ifndef __TDF_UNIX95_SYS_SOCKET_H
#define __TDF_UNIX95_SYS_SOCKET_H

#ifdef __cplusplus
extern "C" {
#endif

#pragma TenDRA declaration block api__unix95__sys_socket begin

#ifndef __TDF_UNIX95_SYS_TYPES_H
#pragma extend interface "../../unix95.api/sys/types.h"
#endif /* __TDF_UNIX95_SYS_TYPES_H */
#ifndef __TDF_UNIX95_SYS_UIO_H
#pragma extend interface "../../unix95.api/sys/uio.h"
#endif /* __TDF_UNIX95_SYS_UIO_H */
#pragma token EXP const : int : SCM_RIGHTS # unix95.socket.SCM_RIGHTS
#pragma token EXP const : int : SOCK_DGRAM # unix95.socket.SOCK_DGRAM
#pragma token EXP const : int : SOCK_STREAM # unix95.socket.SOCK_STREAM
#pragma token EXP const : int : SOCK_SEQPACKET # unix95.socket.SOCK_SEQPACKET
#pragma token EXP const : int : SOL_SOCKET # unix95.socket.SOL_SOCKET
#pragma token EXP const : int : SO_DEBUG # unix95.socket.SO_DEBUG
#pragma token EXP const : int : SO_ACCEPTCONN # unix95.socket.SO_ACCEPTCONN
#pragma token EXP const : int : SO_BROADCAST # unix95.socket.SO_BROADCAST
#pragma token EXP const : int : SO_REUSEADDR # unix95.socket.SO_REUSEADDR
#pragma token EXP const : int : SO_KEEPALIVE # unix95.socket.SO_KEEPALIVE
#pragma token EXP const : int : SO_LINGER # unix95.socket.SO_LINGER
#pragma token EXP const : int : SO_OOBINLINE # unix95.socket.SO_OOBINLINE
#pragma token EXP const : int : SO_SNDBUF # unix95.socket.SO_SNDBUF
#pragma token EXP const : int : SO_RCVBUF # unix95.socket.SO_RCVBUF
#pragma token EXP const : int : SO_ERROR # unix95.socket.SO_ERROR
#pragma token EXP const : int : SO_TYPE # unix95.socket.SO_TYPE
#pragma token EXP const : int : MSG_CTRUNC # unix95.socket.MSG_CTRUNC
#pragma token EXP const : int : MSG_OOB # unix95.socket.MSG_OOB
#pragma token EXP const : int : MSG_PEEK # unix95.socket.MSG_PEEK
#pragma token EXP const : int : MSG_TRUNC # unix95.socket.MSG_TRUNC
#pragma token EXP const : int : MSG_WAITALL # unix95.socket.MSG_WAITALL
#pragma token EXP const : int : AF_UNIX # unix95.socket.AF_UNIX
#pragma token EXP const : int : AF_INET # unix95.socket.AF_INET
#pragma token EXP const : int : SHUT_RD # unix95.socket.SHUT_RD
#pragma token EXP const : int : SHUT_WR # unix95.socket.SHUT_WR
#pragma token EXP const : int : SHUT_RDWR # unix95.socket.SHUT_RDWR
#ifndef __TDF_UNIX95_SYS_SOCKET_H_SA_FAMILY_T
#pragma extend interface "../../shared/unix95.api/sa_famil.h"
#endif /* __TDF_UNIX95_SYS_SOCKET_H_SA_FAMILY_T */
#pragma token NAT __local_sa_data_size # unix95.socket.__local_sa_data_size
#pragma token STRUCT TAG sockaddr # unix95.socket.sockaddr
#pragma token MEMBER sa_family_t : struct sockaddr : sa_family # unix95.socket.sockaddr.sa_family
#pragma token MEMBER char [__local_sa_data_size] : struct sockaddr : sa_data # unix95.socket.sockaddr.sa_data
#pragma token STRUCT TAG msghdr # unix95.socket.msghdr
#pragma token MEMBER void * : struct msghdr : msg_name # unix95.socket.msghdr.msg_name
#pragma token MEMBER size_t : struct msghdr : msg_namelen # unix95.socket.msghdr.msg_namelen
#pragma token MEMBER struct iovec * : struct msghdr : msg_iov # unix95.socket.msghdr.msg_iov
#pragma token MEMBER int : struct msghdr : msg_iovlen # unix95.socket.msghdr.msg_iovlen
#pragma token MEMBER void * : struct msghdr : msg_control # unix95.socket.msghdr.msg_control
#pragma token MEMBER size_t : struct msghdr : msg_controllen # unix95.socket.msghdr.msg_controllen
#pragma token MEMBER int : struct msghdr : msg_flags # unix95.socket.msghdr.msg_flags
#pragma token STRUCT TAG cmsghdr # unix95.socket.cmsghdr
#pragma token MEMBER size_t : struct cmsghdr : cmsg_len # unix95.socket.cmsghdr.cmsg_len
#pragma token MEMBER int : struct cmsghdr : cmsg_level # unix95.socket.cmsghdr.cmsg_level
#pragma token MEMBER int : struct cmsghdr : cmsg_type # unix95.socket.cmsghdr.cmsg_type
#pragma token STRUCT TAG linger # unix95.socket.linger
#pragma token MEMBER int : struct linger : l_onoff # unix95.socket.linger.l_onoff
#pragma token MEMBER int : struct linger : l_linger # unix95.socket.linger.l_linger
#pragma token PROC (EXP rvalue : struct cmsghdr * : ) EXP rvalue : unsigned char * : CMSG_DATA # unix95.socket.CMSG_DATA
#pragma token PROC (EXP rvalue : struct msghdr * : , EXP rvalue : struct cmsghdr * : ) EXP rvalue : struct cmsghdr * : CMSG_NXTHDR # unix95.socket.CMSG_NXTHDR
#pragma token PROC (EXP rvalue : struct msghdr * : ) EXP rvalue : struct cmsghdr * : CMSG_FIRSTHDR # unix95.socket.CMSG_FIRSTHDR
#pragma token FUNC int (int, struct sockaddr *, size_t *) : accept # unix95.socket.accept
#pragma token FUNC int (int, const struct sockaddr *, size_t) : bind # unix95.socket.bind
#pragma token FUNC int (int, const struct sockaddr *, size_t) : connect # unix95.socket.connect
#pragma token FUNC int (int, const struct sockaddr *, size_t *) : getpeername # unix95.socket.getpeername
#pragma token FUNC int (int, const struct sockaddr *, size_t *) : getsockname # unix95.socket.getsockname
#pragma token FUNC int (int, int, int, void *, size_t *) : getsockopt # unix95.socket.getsockopt
#pragma token FUNC int (int, int) : listen # unix95.socket.listen
#pragma token FUNC ssize_t (int, void *, size_t, int) : recv # unix95.socket.recv
#pragma token FUNC ssize_t (int, void *, size_t, int, struct sockaddr *, size_t *) : recvfrom # unix95.socket.recvfrom
#pragma token FUNC ssize_t (int, struct msghdr *, int) : recvmsg # unix95.socket.recvmsg
#pragma token FUNC ssize_t (int, const void *, size_t, int) : send # unix95.socket.send
#pragma token FUNC ssize_t (int, const struct msghdr *, int) : sendmsg # unix95.socket.sendmsg
#pragma token FUNC ssize_t (int, const void *, size_t, int, const struct sockaddr *, size_t) : sendto # unix95.socket.sendto
#pragma token FUNC int (int, int, int, const void *, size_t) : setsockopt # unix95.socket.setsockopt
#pragma token FUNC int (int, int) : shutdown # unix95.socket.shutdown
#pragma token FUNC int (int, int, int) : socket # unix95.socket.socket
#pragma token FUNC int (int, int, int, int [2]) : socketpair # unix95.socket.socketpair

#pragma interface SCM_RIGHTS SOCK_DGRAM SOCK_STREAM SOCK_SEQPACKET
#pragma interface SOL_SOCKET SO_DEBUG SO_ACCEPTCONN SO_BROADCAST
#pragma interface SO_REUSEADDR SO_KEEPALIVE SO_LINGER SO_OOBINLINE SO_SNDBUF
#pragma interface SO_RCVBUF SO_ERROR SO_TYPE MSG_CTRUNC MSG_OOB MSG_PEEK
#pragma interface MSG_TRUNC MSG_WAITALL AF_UNIX AF_INET SHUT_RD SHUT_WR
#pragma interface SHUT_RDWR __local_sa_data_size TAG sockaddr
#pragma interface TAG sockaddr.sa_family TAG sockaddr.sa_data TAG msghdr
#pragma interface TAG msghdr.msg_name TAG msghdr.msg_namelen
#pragma interface TAG msghdr.msg_iov TAG msghdr.msg_iovlen
#pragma interface TAG msghdr.msg_control TAG msghdr.msg_controllen
#pragma interface TAG msghdr.msg_flags TAG cmsghdr TAG cmsghdr.cmsg_len
#pragma interface TAG cmsghdr.cmsg_level TAG cmsghdr.cmsg_type TAG linger
#pragma interface TAG linger.l_onoff TAG linger.l_linger CMSG_DATA
#pragma interface CMSG_NXTHDR CMSG_FIRSTHDR accept bind connect getpeername
#pragma interface getsockname getsockopt listen recv recvfrom recvmsg send
#pragma interface sendmsg sendto setsockopt shutdown socket socketpair

#pragma TenDRA declaration block end

#ifdef __cplusplus
}
#endif

#endif /* __TDF_UNIX95_SYS_SOCKET_H */
