Esempio n. 1
0
        public NetSession(UInt64 sessionID, Socket socket, NetCmdQueue refCmdQueue)
        {
            m_sessionID   = sessionID;
            m_socket      = socket;
            m_refCmdQueue = refCmdQueue;

            m_netStream  = new NetworkStream(socket);
            m_recvStream = new NetRecvStream(sessionID, m_netStream);
        }
Esempio n. 2
0
        public UInt64 CreateSession(Socket socket, NetCmdQueue refCmdQueue)
        {
            UInt64 nNewSessionID = 0;

            lock (m_dicSession)
            {
                nNewSessionID = GetNewSessionID();
                NetSession newSession = new NetSession(nNewSessionID, socket, refCmdQueue);

                newSession.Start();

                m_dicSession.Add(nNewSessionID, newSession);
            }
            return(nNewSessionID);
        }
Esempio n. 3
0
 public NetSession(UInt64 nSessionID, NetCmdQueue refCommandQueue)
 {
     m_nSessionID      = nSessionID;
     m_refCommandQueue = refCommandQueue;
 }
Esempio n. 4
0
 public NetSessionMgr(NetCmdQueue refCommandQueue)
 {
     m_refCommandQueue = refCommandQueue;
 }
Esempio n. 5
0
 public NetAcceptor(CreateSession dlgtCreateSession, NetCmdQueue refCmdQueue)
 {
     m_dlgtCreateSession = dlgtCreateSession;
     m_refCmdQueue       = refCmdQueue;
 }