ShspSocket.internal constructor

ShspSocket.internal(
  1. RawDatagramSocket socket,
  2. MessageCallbackMap _messageCallbacks, [
  3. ICompressionCodec? compressionCodec
])

Internal constructor for factory creation

Implementation

ShspSocket.internal(
  super.socket,
  this._messageCallbacks, [
  ICompressionCodec? compressionCodec,
]) : _compressionCodec = compressionCodec ?? GZipCodec() {
  _onClose = CallbackOn();
  _onError = CallbackOnError();
  _onListening = CallbackOn();
  _setupEventListeners();
}