Changeset 151 in libcf for trunk/include/cf_socket.h
- Timestamp:
- 10/31/13 10:17:24 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/cf_socket.h
r128 r151 16 16 17 17 /** 타임아웃을 설정하지 않음 */ 18 #define CF_SOCKET_NO_TIMEOUT -118 #define CF_SOCKET_NO_TIMEOUT 0 19 19 20 20 #ifdef __cplusplus 21 21 extern "C" { 22 22 #endif 23 24 CF_EXPORT CF_BOOL25 CF_Socket_IsInitialized (void);26 23 27 24 CF_EXPORT int … … 32 29 33 30 CF_EXPORT int 34 CF_Socket_C lose (const int sock);31 CF_Socket_Create (cf_ctx * ctx); 35 32 36 33 CF_EXPORT int 37 CF_Socket_SetOption (const int sock, 34 CF_Socket_Close (cf_ctx ctx); 35 36 CF_EXPORT int 37 CF_Socket_Connect (cf_ctx ctx, 38 const char * ip, 39 const unsigned short port); 40 41 CF_EXPORT int 42 CF_Socket_Server (cf_ctx ctx, 43 const unsigned short port, 44 const int backlog); 45 46 CF_EXPORT int 47 CF_Socket_Accept (const cf_ctx ctx, 48 cf_ctx * client); 49 50 CF_EXPORT int 51 CF_Socket_Send (const cf_ctx ctx, 52 const void * buf, 53 const size_t len); 54 55 CF_EXPORT int 56 CF_Socket_Recv (const cf_ctx ctx, 57 void * buf, 58 const size_t len); 59 60 CF_EXPORT int 61 CF_Socket_SetOption (const cf_ctx ctx, 38 62 const int optname, 39 63 const void * optval, … … 41 65 42 66 CF_EXPORT int 43 CF_Socket_GetOption (const int sock,44 const int optname,45 void * optval,46 size_t * optlen);67 CF_Socket_GetOption (const cf_ctx ctx, 68 const int optname, 69 void * optval, 70 size_t * optlen); 47 71 48 72 CF_EXPORT int 49 CF_Socket_ Connect (const char * ip,50 const unsigned short port);73 CF_Socket_SetTimeOut (cf_ctx ctx, 74 int timeout); 51 75 52 76 CF_EXPORT int 53 CF_Socket_ConnectTimeout (const char * ip, 54 const unsigned short port, 55 const int timeout); 77 CF_Socket_GetIP (const cf_ctx ctx, 78 char * ip); 56 79 57 80 CF_EXPORT int 58 CF_Socket_Server (const unsigned short port, 59 const int backlog); 60 61 CF_EXPORT int 62 CF_Socket_Accept (const int sock); 63 64 CF_EXPORT int 65 CF_Socket_Send (const int sock, 66 const void * buf, 67 const size_t len); 68 69 CF_EXPORT int 70 CF_Socket_SendTimeout (const int sock, 71 const void * buf, 72 const size_t len, 73 const int timeout); 74 75 CF_EXPORT int 76 CF_Socket_Recv (const int sock, 77 void * buf, 78 const size_t len); 79 80 CF_EXPORT int 81 CF_Socket_RecvTimeout (const int sock, 82 void * buf, 83 const size_t len, 84 const int timeout); 81 CF_Socket_GetPort (const cf_ctx ctx, 82 unsigned short * port); 85 83 86 84 #ifdef __cplusplus
Note:
See TracChangeset
for help on using the changeset viewer.