C# Class OpenNos.Core.Networking.Communication.Scs.Server.ScsServerBase

This class provides base functionality for server Classs.
Inheritance: IScsServer
ファイルを表示 Open project: OpenNos/OpenNos

Public Methods

Method Description
Start ( ) : void

Starts the server.

Stop ( ) : void

Stops the server.

Protected Methods

Method Description
CreateConnectionListener ( ) : IConnectionListener

This method is implemented by derived Classs to create appropriate connection listener to listen incoming connection requets.

OnClientConnected ( IScsServerClient client ) : void

Raises ClientConnected event.

OnClientDisconnected ( IScsServerClient client ) : void

Raises ClientDisconnected event.

ScsServerBase ( ) : System

Constructor.

Private Methods

Method Description
Client_Disconnected ( object sender, EventArgs e ) : void

Handles Disconnected events of all connected clients.

ConnectionListener_CommunicationChannelConnected ( object sender, CommunicationChannelEventArgs e ) : void

Handles CommunicationChannelConnected event of _connectionListener object.

Method Details

CreateConnectionListener() protected abstract method

This method is implemented by derived Classs to create appropriate connection listener to listen incoming connection requets.
protected abstract CreateConnectionListener ( ) : IConnectionListener
return IConnectionListener

OnClientConnected() protected method

Raises ClientConnected event.
protected OnClientConnected ( IScsServerClient client ) : void
client IScsServerClient Connected client
return void

OnClientDisconnected() protected method

Raises ClientDisconnected event.
protected OnClientDisconnected ( IScsServerClient client ) : void
client IScsServerClient Disconnected client
return void

ScsServerBase() protected method

Constructor.
protected ScsServerBase ( ) : System
return System

Start() public method

Starts the server.
public Start ( ) : void
return void

Stop() public method

Stops the server.
public Stop ( ) : void
return void