C# Class Griffin.Net.Protocols.Http.HttpMessageEncoder

Used to encode request/response into a byte stream.
Inheritance: IMessageEncoder
Afficher le fichier Open project: jgauffin/Griffin.Framework Class Usage Examples

Méthodes publiques

Méthode Description
Clear ( ) : void

Remove everything used for the last message

HttpMessageEncoder ( ) : System

Initializes a new instance of the HttpMessageEncoder class.

OnSendCompleted ( int bytesTransferred ) : bool

The previous IMessageEncoder.Send has just completed.

true if the message have been sent successfully; otherwise false.

Prepare ( object message ) : void

Are about to send a new message

Can be used to prepare the next message. for instance serialize it etc.

Send ( ISocketBuffer buffer ) : void

Buffer structure used for socket send operations.

Method Details

Clear() public méthode

Remove everything used for the last message
public Clear ( ) : void
Résultat void

HttpMessageEncoder() public méthode

Initializes a new instance of the HttpMessageEncoder class.
public HttpMessageEncoder ( ) : System
Résultat System

OnSendCompleted() public méthode

The previous IMessageEncoder.Send has just completed.
true if the message have been sent successfully; otherwise false.
public OnSendCompleted ( int bytesTransferred ) : bool
bytesTransferred int
Résultat bool

Prepare() public méthode

Are about to send a new message
Can be used to prepare the next message. for instance serialize it etc.
Message is of a type that the encoder cannot handle.
public Prepare ( object message ) : void
message object Message to send
Résultat void

Send() public méthode

Buffer structure used for socket send operations.
public Send ( ISocketBuffer buffer ) : void
buffer ISocketBuffer /// Do note that there are not buffer attached to the structure, you have to assign one yourself using /// . This choice was made /// to prevent unnecessary copy operations. ///
Résultat void