Tizen Sockets Extension API References
This topic lists methods provided by the Tizen Sockets Extension for WebAssembly.
Related Info
ImportantThe
More information regarding the "config.xml" file format and how to add privileges there can be found on Tizen Developers.
http://tizen.org/privilege/internet
privilege is needed when using this extension.More information regarding the "config.xml" file format and how to add privileges there can be found on Tizen Developers.
When possible, the semantics of these functions conform to the POSIX.1-2017 standard. The most notable differences are:
- lack of signals support in Emscripten and in a web environment.
- Tizen Sockets Extension APIs cannot be called from the main thread, which is usually the one running the main function unless
-s PROXY_TO_PTHREAD
or--proxy-to-worker
flags are provided to Emscripten during link time. See Additional flags in the Emscripten documentation. - Socket functions that accept multiple descriptors can accept only one descriptor type at a time. Descriptor types cannot be mixed (meaning that a method can be called with either socket descriptors or file descriptors, but not both). In particular, this applies to poll() and select() methods.
- select() method can be slow due to its internal implementation in Emscripten. It is recommended to use poll() method instead.
The following extensions to sockets are provided:
SOCK_NONBLOCK
andSOCK_CLOEXEC
flags when creating socket()- accept4() method
- IPv4 multicast options in getsockopt() and setsockopt() methods.
- gethostbyaddr() method
- gethostbyname() method
accept() |
- | |
accept4() |
Values in flags :
|
|
bind() |
- | |
close() |
- | |
connect() |
- | |
freeaddrinfo() |
- | |
getaddrinfo() |
- | |
gethostbyaddr() |
- | |
gethostbyname() |
- | |
getpeername() |
- | |
getsockname() |
- | |
getsockopt() |
Combinations of level and optname :
|
|
listen() |
- | |
poll() |
Supported event flags:
Usage notes:
|
|
read() |
- | |
recv() |
Values in flags :
|
|
recvfrom() |
Values in flags :
|
|
recvmsg() |
Values in flags :
|
|
select() |
Usage notes:
|
|
send() |
Values in flags :
|
The Open Group Base Specifications Issue 7, 2018 edition - send |
sendmsg() |
Values in flags :
|
|
sendto() |
Values in flags :
|
|
setsockopt() |
Combinations of level and optname :
|
|
shutdown() |
Values in how :
|
|
socket() |
Values in domain :
Values in type :
Flags bitwise ORed with type argument:
|
|
write() |
- |
Table 1: Tizen Sockets Extension Methods