Main Page | Modules | Alphabetical List | Data Structures | File List | Data Fields | Related Pages

socket.h

00001 #ifndef NET__SOCKET__H__
00002 #define NET__SOCKET__H__
00003 
00004 #include "ipv4.h"
00005 
00021 int socket_tcp(void);
00022 int socket_udp(void);
00023 int socket_connect4(int sock, const ipv4addr* ip, ipv4port port);
00024 int socket_bind4(int sock, const ipv4addr* ip, ipv4port port);
00025 int socket_accept4(int sock, ipv4addr* ip, ipv4port* port);
00026 int socket_recv4(int sock, char* buffer, unsigned buflen,
00027                  ipv4addr* ip, ipv4port* port);
00028 int socket_send4(int sock, const char* buffer, unsigned buflen,
00029                  const ipv4addr* ip, ipv4port port);
00030 int socket_getaddr4(int sock, ipv4addr* ip, ipv4port* port);
00031 int socket_cork(int sock);
00032 int socket_uncork(int sock);
00033 /* @} */
00034 
00037 int socket_unixdgm(void);
00038 int socket_unixstr(void);
00039 int socket_connectu(int sock, const char* path);
00040 int socket_bindu(int sock, const char* path);
00041 int socket_acceptu(int sock);
00042 int socket_recvu(int sock, char* buffer, unsigned buflen);
00043 int socket_sendu(int sock, const char* buffer, unsigned buflen);
00044 
00045 int socket_pairstr(int fd[2]);
00046 int socket_pairdgm(int fd[2]);
00047 /* @} */
00048 
00051 int socket_broadcast(int sock);
00052 int socket_connected(int sock);
00053 int socket_linger(int fd, int onoff, int seconds);
00054 int socket_listen(int sock, int backlog);
00055 int socket_reuse(int sock);
00056 int socket_shutdown(int sock, int shut_rd, int shut_wr);
00057 
00058 int socket_sendfd(int sock, int fd);
00059 int socket_recvfd(int sock);
00060 /* @} */
00061 
00062 /* @} */
00063 
00064 #endif

Generated on Mon Dec 1 13:28:06 2003 for bglibs by doxygen 1.3.3