Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
SocketExceptionFactory.cs
Go to the documentation of this file.
2
4
5internal static class SocketExceptionFactory
6{
8 {
9 private readonly EndPoint _endPoint;
10
11 public override string Message
12 {
13 get
14 {
15 if (_endPoint != null)
16 {
17 return base.Message + " " + _endPoint.ToString();
18 }
19 return base.Message;
20 }
21 }
22
23 public ExtendedSocketException(int errorCode, EndPoint endPoint)
24 : base(errorCode)
25 {
26 _endPoint = endPoint;
27 }
28 }
29
30 public static SocketException CreateSocketException(int socketError, EndPoint endPoint)
31 {
32 return new ExtendedSocketException(socketError, endPoint);
33 }
34}
static SocketException CreateSocketException(int socketError, EndPoint endPoint)