Esempio n. 1
0
        internal NetTraffic(long creationTime)
        {
            this.payloadLoss = new SequenceCounter(true);
              this.payloadDrop = new SequenceCounter(false);
              this.outgoingPing = new PingCounter();
              this.pingWindow = new int[NetConfig.PING_SMOOTHING_WINDOW];
              this.creationTime = creationTime;

              this.lastPayloadSeq = ushort.MaxValue; // "-1"
              this.notificationAck = 0;
              this.pingWindowIndex = 0;

              this.lastPacketRecvTime = creationTime;
              this.lastPayloadRecvTime = creationTime;
              this.lastNotificationRecvTime = creationTime;
              this.lastPongRecvTime = creationTime;

              for (int i = 0; i < this.pingWindow.Length; i++)
            this.pingWindow[i] = -1;
        }
Esempio n. 2
0
        internal NetTraffic(long creationTime)
        {
            payloadLoss       = new SequenceCounter(true);
            payloadDrop       = new SequenceCounter(false);
            outgoingPing      = new PingCounter();
            pingWindow        = new int[NetConfig.PING_SMOOTHING_WINDOW];
            this.creationTime = creationTime;

            lastPayloadSeq  = ushort.MaxValue; // "-1"
            notificationAck = 0;
            pingWindowIndex = 0;

            lastPacketRecvTime       = creationTime;
            lastPayloadRecvTime      = creationTime;
            lastNotificationRecvTime = creationTime;
            lastPongRecvTime         = creationTime;

            for (int i = 0; i < pingWindow.Length; i++)
            {
                pingWindow[i] = -1;
            }
        }