C# 클래스 Lawo.EmberPlusSharp.S101.MessageDecodingStream

Transparently decodes a single S101 message.

At construction, a Message object is first decoded from the ReadBuffer object passed to CreateAsync and made available through the Message property. Afterwards, a call to any of the Read methods of this stream removes data from ReadBuffer object passed to the CreateAsync. The data is then decoded and the decoded form is then returned.

If a message contains multiple packets, their payload is automatically joined such that it can be read through this stream as if the message consisted of only one packet.

상속: NonSeekableStream
파일 보기 프로젝트 열기: Lawo/ember-plus-sharp 1 사용 예제들

Private Properties

프로퍼티 타입 설명
CreateAsync Task
MessageDecodingStream System
ReadDeframedAsync Task
ReadFromCurrentPacketAsync Task
ValidateMessage void

공개 메소드들

메소드 설명
DisposeAsync ( CancellationToken cancellationToken ) : Task
ReadAsync ( byte buffer, int offset, int count, CancellationToken cancellationToken ) : Task

비공개 메소드들

메소드 설명
CreateAsync ( ReadBuffer rawBuffer, byte discardBuffer, Action outOfFrameByteReceived, CancellationToken cancellationToken ) : Task
MessageDecodingStream ( ReadBuffer rawBuffer, byte discardBuffer, Action outOfFrameByteReceived ) : System
ReadDeframedAsync ( byte buffer, int index, int count, CancellationToken cancellationToken ) : Task
ReadFromCurrentPacketAsync ( byte buffer, int offset, int count, CancellationToken cancellationToken ) : Task
ValidateMessage ( S101Message newMessage ) : void

메소드 상세

DisposeAsync() 공개 최종 메소드

public final DisposeAsync ( CancellationToken cancellationToken ) : Task
cancellationToken System.Threading.CancellationToken
리턴 Task

ReadAsync() 공개 최종 메소드

public final ReadAsync ( byte buffer, int offset, int count, CancellationToken cancellationToken ) : Task
buffer byte
offset int
count int
cancellationToken System.Threading.CancellationToken
리턴 Task