MCPcopy
hub / github.com/websockets/ws / address

Method address

lib/websocket-server.js:153–160  ·  view source on GitHub ↗

* Returns the bound address, the address family name, and port of the server * as reported by the operating system if listening on an IP socket. * If the server is listening on a pipe or UNIX domain socket, the name is * returned as a string. * * @return {(Object|String|null)} The add

()

Source from the content-addressed store, hash-verified

151 * @public
152 */
153 address() {
154 if (this.options.noServer) {
155 throw new Error('The server is operating in "noServer" mode');
156 }
157
158 if (!this._server) return null;
159 return this._server.address();
160 }
161
162 /**
163 * Stop the server from accepting new connections and emit the `'close'` event

Callers 6

websocket.test.jsFile · 0.80
runTestFunction · 0.80
listeningFunction · 0.80
ssl.jsFile · 0.80

Calls

no outgoing calls

Tested by 2

runTestFunction · 0.64
listeningFunction · 0.64