public void Process() { ProcessorOnceEvent?.Invoke(this, null); ProcessorOnceEvent = null; ProcessorEvent?.Invoke(this, null); LayoutProcessorEvent?.Invoke(this, null); }
public CServer(string name, int port, int backlog) { mName = name; mPort = port; mBacklog = backlog; mInvokeAcceptConnection = new ProcessorEvent(InvokeAcceptConnection); mInvokeDisconnection = new ProcessorEvent(InvokeDisconnection); mInvokeReceiveData = new ProcessorReceiveEvent(InvokeReceiveData); mInvokeSendData = new ProcessorSendEvent(InvokeSendData); }
public CRemoteManageClient(IMonitorSystemContext context) { mSystemContext = context; mAsyncDoConnected = new ProcessorEvent(AsyncDoConnected); mAsyncDoDisconnected = new ProcessorEvent(AsyncDoDisconnected); mAsyncDoReceiveData = new ProcessorReceiveEvent(AsyncDoReceiveData); mTimer = new System.Threading.Timer(new TimerCallback(OnTimerTick)); mTimer.Change(AutoConnectInterval, AutoConnectInterval); mSendPipeManager.OnSendOperate += new DeleSendOperate(DoSend); //mReceivePipe.OnProcessData += new ProcessorReceiveEvent(AsyncDoReceiveData); //mReceivePipe.Start(); }
public void AddProcessorEvent(ProcessorEvent pEvent) { switch (pEvent) { case ProcessorEvent.StartProcessing: this.counters.CurrentRequests.Increment(); return; case ProcessorEvent.EndProcessing: this.counters.CurrentRequests.Decrement(); return; default: return; } }