Example #1
0
        //---------------------------------------------------------------------
        public void update()
        {
            Service();

            lock (mQueSessionEventLock)
            {
                if (mQueSessionEvent.Count == 0)
                {
                    return;
                }
                SessionEvent se = mQueSessionEvent.Dequeue();

                if (mListener == null)
                {
                    return;
                }

                if (se.connect)
                {
                    mListener.onSessionConnect(se.node_type_local, se.node_type_remote, se.session);
                }
                else
                {
                    mListener.onSessionDisconnect(se.node_type_local, se.node_type_remote, se.session);
                }
            }
        }
Example #2
0
 //---------------------------------------------------------------------
 protected override void OnDisconnect(DisconnectReason reasonCode, string reasonDetail)
 {
     if (mListener != null)
     {
         mListener.onSessionDisconnect(mEntityMgr.NodeType, mRemoteNodeType, mRpcSession);
     }
 }