예제 #1
0
 /// <summary>
 /// 构造函数
 /// </summary>
 /// <param name="socket">维护的Socket对象</param>
 /// <param name="server">维护此连接的服务对象</param>
 public TcpSocketConnection(Socket socket, TcpSocketServer server)
 {
     _socket = socket;
     _server = server;
 }
예제 #2
0
 /// <summary>
 /// 构造函数
 /// 注:默认监听0.0.0.0
 /// </summary>
 /// <param name="port">监听端口</param>
 public WebSocketServer(int port)
 {
     _tcpSocketServer = new TcpSocketServer(port);
 }