UNSTABLE: new API, yet to be vetted.
A generic transport listener for message-oriented protocols.
Methods
receive(p?: Uint8Array): Promise<[Uint8Array, Addr]>
UNSTABLE: new API, yet to be vetted.
Waits for and resolves to the next message to the UDPConn
.
send(p: Uint8Array, addr: Addr): Promise<number>
UNSTABLE: new API, yet to be vetted.
Sends a message to the target.
UNSTABLE: new API, yet to be vetted.
Close closes the socket. Any pending message promises will be rejected with errors.
[[Symbol.asyncIterator]](): AsyncIterableIterator<[Uint8Array, Addr]>