C# Class WebApplications.Utilities.Performance.PerformanceCounterExtensions

Afficher le fichier Open project: webappsuk/CoreLibraries

Méthodes publiques

Méthode Description
GetElapsedTime ( CounterSample oldSample, CounterSample newSample ) : System.Duration

Gets the elapsed time between two samples

SafeNextValue ( [ counter ) : float

Safely gets the next value of a performance counter, by ensuring that a minimum duration has passed since the last next value was requested.

Method Details

GetElapsedTime() public static méthode

Gets the elapsed time between two samples
public static GetElapsedTime ( CounterSample oldSample, CounterSample newSample ) : System.Duration
oldSample System.Diagnostics.CounterSample The old sample.
newSample System.Diagnostics.CounterSample The new sample.
Résultat System.Duration

SafeNextValue() public static méthode

Safely gets the next value of a performance counter, by ensuring that a minimum duration has passed since the last next value was requested.
public static SafeNextValue ( [ counter ) : float
counter [ The counter.
Résultat float