close abstract method

Future<void> close([
  1. int? code,
  2. String? reason
])

Closes the connection, optionally with a WebSocket code/reason.

Implementation

Future<void> close([int? code, String? reason]);