MCPcopy Create free account
hub / github.com/bearlyai/OpenADE / close

Method close

projects/runtime-client/src/client.ts:102–111  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

100 }
101
102 close(): void {
103 this.stopped = true
104 this.socket?.close()
105 this.socket = null
106 for (const pending of this.pending.values()) {
107 pending.reject(new Error("Runtime socket closed"))
108 }
109 this.pending.clear()
110 this.emitStatus("disconnected")
111 }
112
113 async connect(): Promise<void> {
114 if (this.socket?.readyState === WebSocket.OPEN) return

Callers

nothing calls this directly

Calls 4

emitStatusMethod · 0.95
rejectMethod · 0.80
closeMethod · 0.65
clearMethod · 0.65

Tested by

no test coverage detected