Click or drag to resize
UtilitiesEnsureInRangeT Method
Ensures a value is within a specified range.

Namespace: Fiddler
Assembly: FiddlerCore4 (in FiddlerCore4.dll) Version: 4.6.2.0
Syntax
public static T EnsureInRange<T>(
	T current,
	T min,
	T max
)

Parameters

current
Type: T
Current value
min
Type: T
Min value
max
Type: T
Max value

Type Parameters

T
Type of the value

Return Value

Type: T
Returns the provided value, unless it is outside of the specified range, in which case the nearest "fencepost" is returned.
See Also