Share via


ExternalResponse.DataAs Method

Definition

Overloads

Name Description
DataAs(Type)

Attempts to retrieve the underlying data as the specified type.

DataAs<TValue>()

Attempts to retrieve the underlying data as the specified type.

DataAs(Type)

Attempts to retrieve the underlying data as the specified type.

public object? DataAs(Type targetType);
member this.DataAs : Type -> obj
Public Function DataAs (targetType As Type) As Object

Parameters

targetType
Type

The type to which the data should be cast or converted.

Returns

The data cast to the specified type, or null if the data cannot be cast to the specified type.

Applies to

DataAs<TValue>()

Attempts to retrieve the underlying data as the specified type.

public TValue? DataAs<TValue>();
member this.DataAs : unit -> 'Value
Public Function DataAs(Of TValue) () As TValue

Type Parameters

TValue

The type to which the data should be cast or converted.

Returns

TValue

The data cast to the specified type, or null if the data cannot be cast to the specified type.

Applies to