Click or drag to resize

GuardArgumentIsGreaterOrEqualThanT Method (T, T, String, String)

Throws an exception if argumentValue is less than lowerValue.

Namespace:  Enkoni.Framework
Assembly:  Enkoni.Framework (in Enkoni.Framework.dll) Version: 1.3.0.1
Syntax
public static void ArgumentIsGreaterOrEqualThan<T>(
	T lowerValue,
	T argumentValue,
	string argumentName,
	string message
)
where T : struct, new(), IComparable

Parameters

lowerValue
Type: T
The lower value accepted as valid.
argumentValue
Type: T
The argument value to test.
argumentName
Type: SystemString
Name of the argument.
message
Type: SystemString
The message that will be passed to the exception.

Type Parameters

T
A type that implements IComparable.
Exceptions
ExceptionCondition
ArgumentOutOfRangeExceptionValidation error.
Remarks
This method will not test for values. When argumentValue equals , this method will break. To test for values, use the ArgumentIsNotNull(Object, String) method.
See Also