ObjectMarshal.DangerousUnbox<T>(Object) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Unboxes a T
value from an input Object instance.
public static ref T DangerousUnbox<T> (object obj) where T : struct;
static member DangerousUnbox : obj -> 'T (requires 'T : struct)
Public Function DangerousUnbox(Of T As Structure) (obj As Object) As T
Type Parameters
- T
The type of value to unbox.
Parameters
Returns
T
The T
value boxed in obj
.
Exceptions
Thrown when obj
is not of type T
.