Exemplo n.º 1
0
        public C8962Communication()
        {
            _macDic = new Dictionary <string, long>();

            _c8962Server                 = new SocketTCPServer();
            _c8962Server.OnAccept       += OnAccept;
            _c8962Server.OnConnectClose += OnConnectClose;
            _c8962Server.OnDataArrive   += OnDataArrive;
            _c8962Server.OnError        += OnError;
        }
Exemplo n.º 2
0
        private static void SocketTCPServerStart()
        {
            SocketTCPServer socketServer = new SocketTCPServer();

            socketServer.StartAsyncSocket();
        }
 void Start()
 {
     SocketTCPServer.init(Ip, Port);           //开启并初始化服务器
     SocketTCPClient.CreateInstance(Ip, Port); //客户端连接服务器
 }
 void OnApplicationQuit()
 {
     SocketTCPClient.Close();
     SocketTCPServer.Close();
 }
Exemplo n.º 5
0
 public ServerTest(IPEndPoint localPoint)
 {
     Server = new SocketTCPServer(localPoint);
 }