MCPcopy Create free account
hub / github.com/EasyIME/PIME / on_close

Method on_close

python/python3/tornado/websocket.py:455–466  ·  view source on GitHub ↗

Invoked when the WebSocket is closed. If the connection was closed cleanly and a status code or reason phrase was supplied, these values will be available as the attributes ``self.close_code`` and ``self.close_reason``. .. versionchanged:: 4.0 Added ``cl

(self)

Source from the content-addressed store, hash-verified

453 pass
454
455 def on_close(self) -> None:
456 """Invoked when the WebSocket is closed.
457
458 If the connection was closed cleanly and a status code or reason
459 phrase was supplied, these values will be available as the attributes
460 ``self.close_code`` and ``self.close_reason``.
461
462 .. versionchanged:: 4.0
463
464 Added ``close_code`` and ``close_reason`` attributes.
465 """
466 pass
467
468 def close(self, code: Optional[int] = None, reason: Optional[str] = None) -> None:
469 """Closes this Web Socket.

Callers 1

on_connection_closeMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected