C# 클래스 Json.Serialization.JsonFormatter

JSON formatter class for .NET Micro Framework
Can be used to serialize/deserialize with JSON.
파일 보기 프로젝트 열기: devicehive/devicehive-.net-mf 1 사용 예제들

공개 메소드들

메소드 설명
FromJson ( byte bts, Type objType ) : object

Deserializes an object from JSON

This function can be used to parse JSON objecta and arrays.

JsonFormatter ( ) : System

Constructs a JSON formatter

ToJson ( object o ) : string

Serializes an object to a string

Object definition must have the [Serializable] attribute. Serializes only members which are not marked with [NonSerialized] attribute.

비공개 메소드들

메소드 설명
GetNextQuotedString ( string s, int &pos ) : string

Returns nets parameter string

GetSubObject ( string s, int &pos ) : string

Returns next sub-object string

GetValueString ( string s, int &pos ) : string

Extracts a value from a given string

ParseObject ( string JsonString, Type objType ) : object

Parses object from JSON

Works recursively.

SplitArrayStrings ( string s ) : ArrayList

Splits a sprecified string in parts according to JSON array definition

메소드 상세

FromJson() 공개 메소드

Deserializes an object from JSON
This function can be used to parse JSON objecta and arrays.
public FromJson ( byte bts, Type objType ) : object
bts byte JSON input bytes
objType System.Type type of an object to deserialize
리턴 object

JsonFormatter() 공개 메소드

Constructs a JSON formatter
public JsonFormatter ( ) : System
리턴 System

ToJson() 공개 메소드

Serializes an object to a string
Object definition must have the [Serializable] attribute. Serializes only members which are not marked with [NonSerialized] attribute.
public ToJson ( object o ) : string
o object Object to be serialized
리턴 string