close method
Terminates all active connections. If a client remains unclosed, the Dart process may not terminate.
Implementation
@override
Future<void> close() async {
if (_channel != null) {
await _channel!.sink.close();
_channel = null;
_connectCompleter = null;
}
}