Example #1
0
 public void Dispose()
 {
     Socket?.Close();
     Coder?.Dispose();
     _autoResetEvent.Close();
     ReadArgs?.Dispose();
     WriteArgs?.Dispose();
 }
Example #2
0
 public void Clear()
 {
     Socket?.Close();
     Unpacker?.Clear();
     _autoResetEvent?.Close();
     ReadArgs?.Dispose();
     WriteArgs?.Dispose();
     Socket    = null;
     ReadArgs  = null;
     WriteArgs = null;
 }