Partager via


ObjectExtensions.Cast<T>(Object) Method

Definition

Casts the specified object to type T.

public static T Cast<T> (this object obj);
static member Cast : obj -> 'T
<Extension()>
Public Function Cast(Of T) (obj As Object) As T

Type Parameters

T

The type to cast to

Parameters

obj
Object

The input object

Returns

T

Applies to