Пример #1
0
 // spawn threads
 private void PortStatisticsManagerThread()
 {
     while (Thread.CurrentThread.ThreadState == ThreadState.Running)
     {
         Thread.Sleep(updateNetworkInfoEveryMiliseconds);
         portStatisticsManager.Tick();
     }
 }
Пример #2
0
 void PortStatisticsManagerThread()
 {
     portStatisticsManager = new PortStatisticsManager(secondsToKeepNetworkSamples, secondsToClosePIDPortsWithNoRequests, secondsToUpdatePidToPortsTable);
     while (Thread.CurrentThread.ThreadState == ThreadState.Running)
     {
         Thread.Sleep(updateNetworkInfoEveryMiliseconds);
         portStatisticsManager.Tick();
     }
 }