dn_tcp.h
Go to the documentation of this file.
1 #ifndef DN_TCP_H_
2 #define DN_TCP_H_
3 
37 #ifndef _DN_EXP_TCP
38 #define _DN_EXP_TCP
39 #endif /* _DN_EXP_TCP */
40 
41 #ifdef __cplusplus
42 extern "C"
43 {
44 #endif
45 
53  tcp_open_client(void *param, int *sock);
54 
62  tcp_open_server(void *param, int *sock);
63 
70  tcp_close(int *sock);
71 
81  tcp_send(int sock, const char *buf, uint32_t len_buf, void *arg);
82 
93  tcp_recv(int sock, char *buf, uint32_t len_buf, uint32_t *len_recved,
94  uint32_t timeout, void *arg);
95 
103  tcp_set_timeout(int sock, uint32_t timeout);
104 
112  tcp_clear(int sock, uint32_t timeout);
113 
123  tcp_accept(int sock, int *client);
124 
135  tcp_set_keepalive(int sock, int enable, uint32_t idle, uint32_t interval,
136  uint32_t count);
137 
145  tcp_set_nodelay(int sock, int enable);
146 
147 #ifdef __cplusplus
148 }
149 #endif
150 
151 #endif /* DN_TCP_H_ */
unsigned uint32_t
Definition: stdint.h:43
_DN_EXP_TCP HRESULT tcp_open_server(void *param, int *sock)
Opens TCP server.
Definition: dn_tcp.c:254
_DN_EXP_TCP HRESULT tcp_set_keepalive(int sock, int enable, uint32_t idle, uint32_t interval, uint32_t count)
Sets keep alive option.
Definition: dn_tcp.c:485
_DN_EXP_TCP HRESULT tcp_set_nodelay(int sock, int enable)
Sets no delay option.
Definition: dn_tcp.c:500
_DN_EXP_TCP HRESULT tcp_clear(int sock, uint32_t timeout)
Clears the received buffer.
Definition: dn_tcp.c:417
int32_t HRESULT
Definition: dn_common.h:61
_DN_EXP_TCP HRESULT tcp_recv(int sock, char *buf, uint32_t len_buf, uint32_t *len_recved, uint32_t timeout, void *arg)
Receives TCP packet.
Definition: dn_tcp.c:364
_DN_EXP_TCP HRESULT tcp_set_timeout(int sock, uint32_t timeout)
Sets timeout value to the TCP socket.
Definition: dn_tcp.c:405
_DN_EXP_TCP HRESULT tcp_send(int sock, const char *buf, uint32_t len_buf, void *arg)
Sends TCP packet.
Definition: dn_tcp.c:319
_DN_EXP_TCP HRESULT tcp_accept(int sock, int *client)
TCP server accepts a TCP client.
Definition: dn_tcp.c:448
_DN_EXP_TCP HRESULT tcp_close(int *sock)
Closes the socket.
Definition: dn_tcp.c:305
_DN_EXP_TCP HRESULT tcp_open_client(void *param, int *sock)
Opens TCP client.
Definition: dn_tcp.c:107
#define _DN_EXP_TCP
Definition: dn_tcp.h:38


bcap_core
Author(s): DENSO WAVE INCORPORATED
autogenerated on Mon Jun 10 2019 13:12:20