C# Class Netduino.WebServer.Core.Json.JsonPrimitives

Exibir arquivo Open project: martinbuberl/Netduino

Public Methods

Method Description
Deserialize ( string json ) : object

Deserializes the specified Json string into an object whose type matches what was discovered in the PropertyTable.

DumpObjects ( Hashtable hash, int level ) : void
Serialize ( object o ) : string

Convert a value to JSON.

For objects, only public fields are converted.

Private Methods

Method Description
DumpObjectArray ( ArrayList array, int level ) : void
GetSerializeState ( object o ) : SerializeStatus

Determines if the specified object needs to be serialized. It needs to be serialized if it's a class that contains properties that need enumeration. All other objects that can be directly returned, such as ints, strings, etc, do not need to be serialized.

Method Details

Deserialize() public static method

Deserializes the specified Json string into an object whose type matches what was discovered in the PropertyTable.
public static Deserialize ( string json ) : object
json string
return object

DumpObjects() public static method

public static DumpObjects ( Hashtable hash, int level ) : void
hash System.Collections.Hashtable
level int
return void

Serialize() public static method

Convert a value to JSON.
For objects, only public fields are converted.
public static Serialize ( object o ) : string
o object The value to convert. Supported types are: Boolean, String, Byte, (U)Int16, (U)Int32, Float, Double, Decimal, JsonObject, JsonArray, Array, Object and null.
return string