Guard.IsNotOfType Method

Definition

Overloads

IsNotOfType(Object, Type, String)

Asserts that the input value is not of a specific type.

IsNotOfType<T>(Object, String)

Asserts that the input value is not of a specific type.

IsNotOfType(Object, Type, String)

Asserts that the input value is not of a specific type.

public static void IsNotOfType (object value, Type type, string name);
static member IsNotOfType : obj * Type * string -> unit
Public Shared Sub IsNotOfType (value As Object, type As Type, name As String)

Parameters

value
Object

The input Object to test.

type
Type

The type to look for.

name
String

The name of the input parameter being tested.

Exceptions

Thrown if the type of value is the same as type.

Applies to

IsNotOfType<T>(Object, String)

Asserts that the input value is not of a specific type.

public static void IsNotOfType<T> (object value, string name);
static member IsNotOfType : obj * string -> unit
Public Shared Sub IsNotOfType(Of T) (value As Object, name As String)

Type Parameters

T

The type of the input value.

Parameters

value
Object

The input Object to test.

name
String

The name of the input parameter being tested.

Exceptions

Thrown if value is of type T.

Applies to