TCP sock definitions. More...
TCP sock definitions.
Definition in file tcp.h.
#include <errno.h>#include <stdint.h>#include <stdlib.h>#include <sys/types.h>#include "net/sock.h"#include "sock_types.h"
Include dependency graph for tcp.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Typedefs | |
| typedef struct _sock_tl_ep | sock_tcp_ep_t |
| An end point for a TCP sock object. | |
| typedef struct sock_tcp | sock_tcp_t |
| Type for a TCP sock object. More... | |
| typedef struct sock_tcp_queue | sock_tcp_queue_t |
| Type for a TCP listening queue. More... | |
Functions | |
| int | sock_tcp_connect (sock_tcp_t *sock, const sock_tcp_ep_t *remote, uint16_t local_port, uint16_t flags) |
| Establishes a new TCP sock connection. More... | |
| int | sock_tcp_listen (sock_tcp_queue_t *queue, const sock_tcp_ep_t *local, sock_tcp_t *queue_array, unsigned queue_len, uint16_t flags) |
Listen for an incoming connection request on local end point. More... | |
| void | sock_tcp_disconnect (sock_tcp_t *sock) |
| Disconnects a TCP connection. More... | |
| void | sock_tcp_stop_listen (sock_tcp_queue_t *queue) |
| Stops listening on TCP listening queue. More... | |
| int | sock_tcp_get_local (sock_tcp_t *sock, sock_tcp_ep_t *ep) |
| Gets the local end point of a TCP sock object. More... | |
| int | sock_tcp_get_remote (sock_tcp_t *sock, sock_tcp_ep_t *ep) |
| Gets the remote end point of a TCP sock object. More... | |
| int | sock_tcp_queue_get_local (sock_tcp_queue_t *queue, sock_tcp_ep_t *ep) |
| Gets the local end point of a TCP sock queue object. More... | |
| int | sock_tcp_accept (sock_tcp_queue_t *queue, sock_tcp_t **sock, uint32_t timeout) |
| Receives and handles TCP connection requests from other peers. More... | |
| ssize_t | sock_tcp_read (sock_tcp_t *sock, void *data, size_t max_len, uint32_t timeout) |
| Reads data from an established TCP stream. More... | |
| ssize_t | sock_tcp_write (sock_tcp_t *sock, const void *data, size_t len) |
| Writes data to an established TCP stream. More... | |