C# Class OpenStory.Server.Processing.ServerSession

Represents an encrypted network session.
Inheritance: OpenStory.Networking.EncryptedNetworkSession, IServerSession
Exibir arquivo Open project: shoftee/OpenStory Class Usage Examples

Public Methods

Method Description
Push ( ) : void

Starts the asynchronous packet sending process.

ServerSession ( IPacketCodeTable packetCodeTable ) : System

Initializes a new instance of the ServerSession class.

Start ( EndpointCrypto endpointCrypto, HandshakeInfo handshakeInfo ) : void

Private Methods

Method Description
ConstructHandshakePacket ( HandshakeInfo handshakeInfo ) : byte[]
ConstructHandshakePacketContent ( HandshakeInfo handshakeInfo ) : byte[]
ContinuePushAsynchronous ( IAsyncResult result ) : void

Continues packet processing after a successful asynchronous push is complete.

HandlePacketReceived ( object sender, PacketReceivedEventArgs e ) : void
OnReadyForPush ( ) : void
StartPushing ( ) : void
TryContinuePushSynchronous ( byte &packet ) : bool

Attempts to retrieve another packet for processing.

If there were no packets to process, packet will be and isPushing will be set to false.

TryPushAsync ( byte packet ) : bool

Raises the PacketProcessing event for the specified packet data, if possible asynchronously.

Method Details

Push() public method

Starts the asynchronous packet sending process.
public Push ( ) : void
return void

ServerSession() public method

Initializes a new instance of the ServerSession class.
public ServerSession ( IPacketCodeTable packetCodeTable ) : System
packetCodeTable IPacketCodeTable
return System

Start() public method

/// Thrown if or are . ///
public Start ( EndpointCrypto endpointCrypto, HandshakeInfo handshakeInfo ) : void
endpointCrypto OpenStory.Cryptography.EndpointCrypto
handshakeInfo OpenStory.Common.IO.HandshakeInfo
return void