[]
        
(Showing Draft Content)

C1.JsonNet.JsonHelper.DeserializeObject

DeserializeObject Method

DeserializeObject<T>(string, JsonSetting)

Deserializes the JSON to the specified .NET type using JsonSetting.

Declaration
public static T DeserializeObject<T>(string strJson, JsonSetting js = null)
Parameters
Type Name Description
string strJson

The object to deserialize.

JsonSetting js

The JsonSetting used to deserialize the object. If this is null, default serialization settings will be used.

Returns
Type Description
T

The deserialized object from the JSON string.

Type Parameters
Name Description
T

The type of the object to deserialize to.

DeserializeObject(string, JsonSetting)

Deserializes the JSON to the specified .NET type using JsonSetting.

Declaration
public static object DeserializeObject(string strJson, JsonSetting js = null)
Parameters
Type Name Description
string strJson

The object to deserialize.

JsonSetting js

The JsonSetting used to deserialize the object. If this is null, default serialization settings will be used.

Returns
Type Description
object

The deserialized object from the JSON string.

DeserializeObject(string, Type, JsonSetting)

Deserializes the JSON to the specified type using JsonSetting.

Declaration
public static object DeserializeObject(string strJson, Type type, JsonSetting js = null)
Parameters
Type Name Description
string strJson

The object to deserialize.

Type type

The type the json will be deserialized.

JsonSetting js

The JsonSetting used to deserialize the object. If this is null, default serialization settings will be used.

Returns
Type Description
object

The deserialized object from the JSON string.