Readonly [initProtected _closedProtected addressReadonly closedPResolved when the underlying server is closed.
Readonly connectionThe connection of the client.
Readonly connectionMap of connections with connectionId keys that correspond to WebSocketConnection values.
Protected loggerProtected resolveBoolean that indicates whether the internal server is closed or not.
Destroys WebSocketClient
Optional errorThe error code to send to connections on closing
Optional errorThe error message to send to connections on closing
Optional force?: booleanWhen force is false, the returned promise will wait for all streams and connections to close naturally before resolving.
Protected handleProtected handleProtected handleProtected handleAll connection errors are redispatched as client errors.
Connection errors encompass both graceful closes and non-graceful closes.
This also includes ErrorWebSocketConnectionInternal
Protected handleStatic createOptional codeOptional config?: Partial<WebSocketConfig>Optional logger?: LoggerOptional reasonOptional resolveOptional ctx: Partial<ContextTimedInput>Generated using TypeDoc
You must provide an error handler
addEventListener('error'). Otherwise, errors will just be ignored.Events: