다음을 통해 공유


JsonExtensions.TryConvertTo Method

Definition

Overloads

TryConvertTo<TType>(JToken, TType)

Checks if a conversion from the supplied Newtonsoft.Json.Linq.JToken to a TType can be made.

TryConvertTo<TType>(String, TType)

Checks if a conversion from the supplied Newtonsoft.Json.Linq.JToken to a TType can be made.

TryConvertTo<TType>(JToken, TType)

Checks if a conversion from the supplied Newtonsoft.Json.Linq.JToken to a TType can be made.

public static bool TryConvertTo<TType> (this Newtonsoft.Json.Linq.JToken jobject, out TType result);
static member TryConvertTo : Newtonsoft.Json.Linq.JToken * 'ype -> bool
<Extension()>
Public Function TryConvertTo(Of TType) (jobject As JToken, ByRef result As TType) As Boolean

Type Parameters

TType

The type to convert to.

Parameters

jobject
Newtonsoft.Json.Linq.JToken

The Newtonsoft.Json.Linq.JObject.

result
TType

The result.

Returns

Applies to

TryConvertTo<TType>(String, TType)

Checks if a conversion from the supplied Newtonsoft.Json.Linq.JToken to a TType can be made.

public static bool TryConvertTo<TType> (this string str, out TType result);
static member TryConvertTo : string * 'ype -> bool
<Extension()>
Public Function TryConvertTo(Of TType) (str As String, ByRef result As TType) As Boolean

Type Parameters

TType

The type to convert to.

Parameters

str
String

The string.

result
TType

The result.

Returns

Applies to