예제 #1
0
    /// <summary>
    /// 异步连接服务器回调
    /// </summary>
    /// <param name="ar"></param>
    private void ConnectCallBack(IAsyncResult ar)
    {
        Socket socket = (Socket)ar.AsyncState;

        socket.EndConnect(ar);

        session = new SessionClient();
        session.AsyncReceive(socket);
    }