C# 클래스 Amazon.Runtime.Internal.Transform.JsonUnmarshallerContext

Wraps a json string for unmarshalling. Each Read() operation gets the next token. TestExpression() is used to match the current key-chain to an xpath expression. The general pattern looks like this: JsonUnmarshallerContext context = new JsonUnmarshallerContext(jsonString); while (context.Read()) { if (context.IsKey) { if (context.TestExpresion("path/to/element")) { myObject.stringMember = stringUnmarshaller.GetInstance().Unmarshall(context); continue; } } }
상속: Amazon.Runtime.Internal.Transform.UnmarshallerContext
파일 보기 프로젝트 열기: aws/aws-sdk-net 1 사용 예제들

공개 메소드들

메소드 설명
JsonUnmarshallerContext ( Stream responseStream, bool maintainResponseBody, IWebResponseData responseData ) : System

Wrap the jsonstring for unmarshalling.

Peek ( JsonToken token ) : bool

Peeks at the next token. This peek implementation reads the next token and makes the subsequent Read() return the same data. If Peek is called successively, it will return the same data. Only the first one calls Read(), subsequent calls will return the same data until a Read() call is made.

Peek ( ) : int

Peeks at the next (non-whitespace) character in the jsonStream.

Read ( ) : bool

Reads to the next token in the json document, and updates the context accordingly.

ReadText ( ) : string

Returns the text contents of the current token being parsed.

보호된 메소드들

메소드 설명
Dispose ( bool disposing ) : void

비공개 메소드들

메소드 설명
StreamPeek ( ) : int

Peeks at the next character in the stream. If the data isn't buffered into the StreamReader (Peek() returns -1), we flush the buffered data and try one more time.

UpdateContext ( ) : void

메소드 상세

Dispose() 보호된 메소드

protected Dispose ( bool disposing ) : void
disposing bool
리턴 void

JsonUnmarshallerContext() 공개 메소드

Wrap the jsonstring for unmarshalling.
public JsonUnmarshallerContext ( Stream responseStream, bool maintainResponseBody, IWebResponseData responseData ) : System
responseStream Stream Stream that contains the JSON for unmarshalling
maintainResponseBody bool If set to true, maintains a copy of the complete response body as the stream is being read.
responseData IWebResponseData Response data coming back from the request
리턴 System

Peek() 공개 메소드

Peeks at the next token. This peek implementation reads the next token and makes the subsequent Read() return the same data. If Peek is called successively, it will return the same data. Only the first one calls Read(), subsequent calls will return the same data until a Read() call is made.
public Peek ( JsonToken token ) : bool
token JsonToken Token to peek.
리턴 bool

Peek() 공개 메소드

Peeks at the next (non-whitespace) character in the jsonStream.
public Peek ( ) : int
리턴 int

Read() 공개 메소드

Reads to the next token in the json document, and updates the context accordingly.
public Read ( ) : bool
리턴 bool

ReadText() 공개 메소드

Returns the text contents of the current token being parsed.
public ReadText ( ) : string
리턴 string