Takes a JSON string and attempts to create a .NET object from this structure. An input type is required and any type that is serialized to must support a parameterless constructor.
The de-serializer instantiates each object and runs through the properties
The deserializer supports
- All simple types
- Most POCO objects and Hierarchical POCO objects
- Arrays and Object Arrays
- IList based collections
Note that the deserializer doesn't support DataSets/Tables/Rows like the serializer as there's no type information available from the client to create these objects on the fly.
public object Deserialize( string JSONText,
Type ValueType );
Return Value
The parsed object or null on failure. An exception is thrown if the type cannot be created
Parameters
JSONText
A string of JSON text passed from the client.
ValueType
The type of the object that is to be created from the JSON text.
See also:
Class JSONSerializer