C# 클래스 OpenStory.Networking.SendDescriptor

상속: DescriptorBase
파일 보기 프로젝트 열기: shoftee/OpenStory 1 사용 예제들

공개 메소드들

메소드 설명
SendDescriptor ( IDescriptorContainer container ) : System

Initializes a new instance of the SendDescriptor class.

Write ( byte data ) : void

Writes a byte array to the stream.

보호된 메소드들

메소드 설명
OnClosed ( ) : void

비공개 메소드들

메소드 설명
BeginSend ( ) : void
EndSendAsynchronous ( object sender, SocketAsyncEventArgs args ) : void

Asynchronous EndSend, also the callback for the Completed event.

If there is more data to send, this method will call BeginSend().

EndSendSynchronous ( SocketAsyncEventArgs args ) : bool

Synchronous EndSend.

This method will return true if there is more data to send. If there is no more data or if there was a connection error, it will return false.

HandleTransferredData ( SocketAsyncEventArgs args ) : bool

Handles the data which was transferred using the given SocketAsyncEventArgs object.

This method advances the sentBytes field forward and moves to the next segment in the queue if the current has finished sending.

If there was a connection error, this method will return . If all the queued data has been sent, this method will set isSending to and return . Otherwise it will return .

ResetBuffer ( ) : void

Looks at the current segment and adjusts the SocketArgs buffer to it.

메소드 상세

OnClosed() 보호된 메소드

protected OnClosed ( ) : void
리턴 void

SendDescriptor() 공개 메소드

Initializes a new instance of the SendDescriptor class.
/// Thrown if is . ///
public SendDescriptor ( IDescriptorContainer container ) : System
container IDescriptorContainer The containing this instance.
리턴 System

Write() 공개 메소드

Writes a byte array to the stream.
/// Thrown if this session is not open. /// /// Thrown if is . ///
public Write ( byte data ) : void
data byte The data to write.
리턴 void