Language

ClientUtilities.AssertInRange<T>(T, T, T, String) Method

Definition

Throws if value is less than the minimum or greater than the maximum.

public:
generic <typename T>
 where T : IComparable<T> static void AssertInRange(T value, T minimum, T maximum, System::String ^ name);
public static void AssertInRange<T>(T value, T minimum, T maximum, string name) where T : IComparable<T>;
static member AssertInRange : 'T * 'T * 'T * string -> unit (requires 'T :> IComparable<'T>)
Public Shared Sub AssertInRange(Of T As IComparable(Of T)) (value As T, minimum As T, maximum As T, name As String)

Type Parameters

T

The type of to validate which implements IComparable<T>.

Parameters

value
T

The value to validate.

minimum
T

The minimum value to compare.

maximum
T

The maximum value to compare.

name
String

The name of the parameter.

Applies to