Esempio n. 1
0
 /// <summary>
 /// Throws an exception with message format ns message<br/>buffer.
 /// </summary>
 public NetStateMsgException(INetState ns, string message, byte[] buffer, int length)
     : base($"{(ns?.ToString() ?? "unknown")} {message}{Environment.NewLine}{BufferFormat.AsString(buffer, length)}")
 {
 }
Esempio n. 2
0
 /// <summary>
 /// Throws an exception with message format ns message<br/>buffer.
 /// </summary>
 public NetStateMsgException(INetState ns, string message, PacketReader reader)
     : base($"{(ns?.ToString() ?? "unknown")} {message}{Environment.NewLine}{BufferFormat.AsString(reader.Buffer, reader.Length)}")
 {
 }