//--------------------------------------------------------------------- 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); } } }
//--------------------------------------------------------------------- protected override void OnDisconnect(DisconnectReason reasonCode, string reasonDetail) { if (mListener != null) { mListener.onSessionDisconnect(mEntityMgr.NodeType, mRemoteNodeType, mRpcSession); } }