Creates a server that will listen on a local address, such as 0.0.0.0:5683,
or port 0 for a free one.
Whether the server holds a bound socket.
The port the server listens on, which names the one the system chose for
port 0, or null while it is not connected.
Binds the socket and starts answering requests. Rejects when the address cannot be bound.
Closes the socket, keeping the resources and filters.
Counts the clients observing a resource.
Waits for the next reading sent to a path the server takes. Rejects when the server is not connected.
OptionaltimeoutMs: number | null
how long to wait before rejecting; a reading that arrives later waits for the next receive.
Sets a resource's state and notifies every observer of it: bytes, or text such as a command. Rejects when the server is not connected.
Takes the readings sent to the paths a filter matches, with + for one
level and # for the rest.
A CoAP server: the end that nodes send their readings to and observe their commands on.
A PUT or POST to a path matching one of its
subscribefilters is answered 2.04 Changed and delivered torecv, and one to any other path 4.04 Not Found.sendsets a resource's state, which a GET reads and every observer is notified of.senddoes not wait for arecvthat is waiting, so a gateway sends commands while it listens for readings.