Chat Support
Loupe - Log - Monitor - Resolve
Gibraltar.Agent.Metrics Namespace / SampledMetricDefinition Class / RequiresDivisor Method
A SamplingType enum value to check.

RequiresDivisor Method (SampledMetricDefinition)
Checks the provided SamplingType enum value to determine if that sampling type requires two values per sample.
Syntax
'Declaration
 
Public Shared Function RequiresDivisor( _
   ByVal samplingType As SamplingType _
) As Boolean
 

Parameters

samplingType
A SamplingType enum value to check.

Return Value

True if the given sampling type requires a second value for each sample as the divisor.
Remarks
Sampled metrics sample either single values (*Count sampling types) or pairs of values (*Fraction sampling types), determined by their sampling type. This method distinguishes between the two scenarios. The *Fraction sampling types record a numerator and a divisor for each sample, so when defining sampled metric counters with SampledMetric and SampledMetricValue attributes, these sampling types require a corresponding SampledMetricDivisor attribute for the same counter name. The *Count sampling types only record a single value for each sample, so they do not need a divisor to be specified.
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also