Go to the documentation of this file.
268 #ifndef NET_SOCK_IP_H
269 #define NET_SOCK_IP_H
273 #include <sys/types.h>
277 #if defined (__clang__)
278 # pragma clang diagnostic push
279 # pragma clang diagnostic ignored "-Wtypedef-redefinition"
296 #if defined (__clang__)
297 # pragma clang diagnostic pop
508 #include "sock_types.h"
sock_ip_ep_t remote
remote end-point
int sock_ip_get_remote(sock_ip_t *sock, sock_ip_ep_t *ep)
Gets the remote end point of a raw IPv4/IPv6 sock object.
sock_ip_ep_t local
local end-point
int sock_ip_create(sock_ip_t *sock, const sock_ip_ep_t *local, const sock_ip_ep_t *remote, uint8_t proto, uint16_t flags)
Creates a new raw IPv4/IPv6 sock object.
uint16_t flags
option flags
ssize_t sock_ip_recv_buf(sock_ip_t *sock, void **data, void **buf_ctx, uint32_t timeout, sock_ip_ep_t *remote)
Provides stack-internal buffer space containing an IPv4/IPv6 message from remote end point.
void sock_ip_close(sock_ip_t *sock)
Closes a raw IPv4/IPv6 sock object.
ssize_t sock_ip_recv(sock_ip_t *sock, void *data, size_t max_len, uint32_t timeout, sock_ip_ep_t *remote)
Receives a message over IPv4/IPv6 from remote end point.
ssize_t sock_ip_send(sock_ip_t *sock, const void *data, size_t len, uint8_t proto, const sock_ip_ep_t *remote)
Sends a message over IPv4/IPv6 to remote end point.
int sock_ip_get_local(sock_ip_t *sock, sock_ip_ep_t *ep)
Gets the local end point of a raw IPv4/IPv6 sock object.
Common sock API definitions.
Abstract IP end point and end point for a raw IP sock object.