Version

Clamp Method

Returns the specified value clamped to the specified range.
Syntax
public static double Clamp( 
   double value,
   double minimum,
   double maximum
)

Parameters

value
Value to clamp.
minimum
Range minimum.
maximum
Range maximum.

Return Value

Clamped value.
Requirements

Target Platforms: Android 4.4+, iOS 8+

Development Environments: Visual Studio 2015+, Visual Studio for Mac Preview, Xamarin for Visual Studio 4.2+

See Also