コード例 #1
0
        protected virtual void OnDatagramHandled()
        {
            EventHandler <TSessionEventArgs> handler = this.DatagramHandled;

            if (handler != null)
            {
                TSessionEventArgs e = new TSessionEventArgs(this);
                handler(this, e);
            }
        }
コード例 #2
0
ファイル: TSocketServerBase.cs プロジェクト: Vlanta/CspBase
        protected virtual void OnDatagramHandled(object sender, TSessionEventArgs e)
        {
            Interlocked.Decrement(ref m_datagramQueueLength);

            EventHandler <TSessionEventArgs> handler = this.DatagramHandled;

            if (handler != null)
            {
                handler(this, e);
            }
        }
コード例 #3
0
ファイル: TSocketServerBase.cs プロジェクト: Vlanta/CspBase
        protected virtual void OnSessionTimeout(TSession session)
        {
            Interlocked.Decrement(ref m_sessionCount);

            EventHandler <TSessionEventArgs> handler = this.SessionTimeout;

            if (handler != null)
            {
                TSessionEventArgs e = new TSessionEventArgs(session);
                handler(this, e);
            }
        }
コード例 #4
0
ファイル: TSocketServerBase.cs プロジェクト: Vlanta/CspBase
        protected virtual void OnDatagramOversizeError(object sender, TSessionEventArgs e)
        {
            Interlocked.Increment(ref m_receivedDatagramCount);
            Interlocked.Increment(ref m_errorDatagramCount);

            EventHandler <TSessionEventArgs> handler = this.DatagramOversizeError;

            if (handler != null)
            {
                handler(this, e);
            }
        }
コード例 #5
0
ファイル: TSessionBase.cs プロジェクト: Vlanta/CspBase
 protected virtual void OnDatagramOversizeError()
 {
     EventHandler<TSessionEventArgs> handler = this.DatagramOversizeError;
     if (handler != null)
     {
         TSessionEventArgs e = new TSessionEventArgs(this);
         handler(this, e);
     }
 }
コード例 #6
0
ファイル: TSessionBase.cs プロジェクト: Vlanta/CspBase
 protected virtual void OnDatagramAccepted()
 {
     EventHandler<TSessionEventArgs> handler = this.DatagramAccepted;
     if (handler != null)
     {
         TSessionEventArgs e = new TSessionEventArgs(this);
         handler(this, e);
     }
 }