api

platform_api.ch

Declarations in platform_api.ch

1 declarationsnet

Declarations

Public only
net#
Publicnamespace
namespace net
socket#
function
func socket(af : int, typ : int, protocol : int) : int
POSIX declarations
bind#
function
func bind(s : int, name : *char, namelen : int) : int
listen#
function
func listen(s : int, backlog : int) : int
connect#
function
func connect(s : int, name : *char, namelen : int) : int
accept#
function
func accept(s : int, addr : *char, addrlen : *int) : int
recv#
function
func recv(s : int, buf : *char, len : int, flags : int) : int
send#
function
func send(s : int, buf : *char, len : int, flags : int) : int
close#
function
func close(fd : int) : int
setsockopt#
function
func setsockopt(s : int, level : int, optname : int, optval : *char, optlen : int) : int
getaddrinfo#
function
func getaddrinfo(node : *char, service : *char, hints : *char, res : **char) : int
freeaddrinfo#
function
func freeaddrinfo(res : *char) : void
fcntl#
function
func fcntl(fd : int, cmd : int, _ : any) : int
open#
function
func open(path : *char, flags : int, mode : int) : int
file I/O + sendfile
lseek#
function
func lseek(fd : int, offset : longlong, whence : int) : longlong
sendfile#
function
func sendfile(out_fd : int, in_fd : int, offset : *longlong, count : size_t) : longlong
Linux sendfile: ssize_t sendfile(int out_fd, int in_fd, off_t *offset, size_t count);
startup#
function
func startup() : void
cleanup#
function
func cleanup() : void
sock_socket#
function
func sock_socket(af : int, typ : int, proto : int) : Socket
sock_bind#
function
func sock_bind(s : Socket, addr : *char, addrlen : int) : int
sock_listen#
function
func sock_listen(s : Socket, backlog : int) : int
sock_connect#
function
func sock_connect(s : Socket, addr : *char, addrlen : int) : int
sock_accept#
function
func sock_accept(s : Socket, addr : *char, addrlen : *int) : Socket
sock_recv#
function
func sock_recv(s : Socket, buf : *char, len : int) : int
sock_send#
function
func sock_send(s : Socket, buf : *char, len : int) : int
sock_close#
function
func sock_close(s : Socket) : void
sock_setsockopt#
function
func sock_setsockopt(s : Socket, level : int, optname : int, optval : *char, optlen : int) : int
sock_getaddrinfo#
function
func sock_getaddrinfo(node : *char, service : *char, hints : *char, res : **char) : int
sock_freeaddrinfo#
function
func sock_freeaddrinfo(res : *char) : void
set_nonblocking#
Publicfunction
func set_nonblocking(s : Socket) : void
poll wrapper for timed I/O (stub - use non-blocking accept instead)
set_blocking#
Publicfunction
func set_blocking(s : Socket) : void