interface Deno.Listener
A generic network listener for stream-oriented protocols.
Type Parameters Jump to heading
Jump to headingT extends Conn = ConnJump to headingA extends Addr = AddrProperties Jump to heading
readonly
Jump to headingaddr: AReturn the address of the Listener.
Methods Jump to heading
Jump to headingaccept(): Promise<T>Waits for and resolves to the next connection to the Listener.
Jump to headingclose(): voidClose closes the listener. Any pending accept promises will be rejected with errors.
Jump to heading[[Symbol.asyncIterator]](): AsyncIterableIterator<T>Jump to headingref(): voidMake the listener block the event loop from finishing.
Note: the listener blocks the event loop from finishing by default.
This method is only meaningful after .unref() is called.
Jump to headingunref(): voidMake the listener not block the event loop from finishing.