Exemple #1
0
 public void Reset()
 {
     sequence = 0;
     for (int i = 0; i < config.FragmentReassemblyBufferSize; i++)
     {
         fragmentReassembly.AtIndex(i)?.PacketDataBuffer.SetSize(0);
     }
     sentPackets.Reset();
     receivedPackets.Reset();
     fragmentReassembly.Reset();
 }
 public override void Reset()
 {
     packetController.Reset();
     sendBuffer.Reset();
     ackBuffer.Reset();
     lastBufferFlush           = -1.0;
     lastMessageSend           = 0.0;
     congestionControl         = false;
     lastCongestionSwitchTime  = 0.0;
     congestionDisableTimer    = 0.0;
     congestionDisableInterval = 5.0;
     sequence      = 0;
     nextReceive   = 0;
     oldestUnacked = 0;
 }
        public void Reset()
        {
            this.sequence = 0;

            for (int i = 0; i < config.FragmentReassemblyBufferSize; i++)
            {
                FragmentReassemblyData reassemblyData = fragmentReassembly.AtIndex(i);
                if (reassemblyData != null)
                {
                    reassemblyData.PacketDataBuffer.SetSize(0);
                }
            }

            sentPackets.Reset();
            receivedPackets.Reset();
            fragmentReassembly.Reset();
        }