close method

Future<void> close()

Releases the bound socket. Calling this more than once is safe.

Implementation

Future<void> close() async {
  if (_closed) {
    return;
  }
  _closed = true;
  await _server.close(force: true);
}