C# Class Mycroft.Server.TcpServer

Starts Mycroft's network communications and owns resources in the server
Inheritance: ICommandable
Afficher le fichier Open project: rit-sse-mycroft/core Class Usage Examples

Méthodes publiques

Méthode Description
Issue ( Command command ) : void

Allow the server to be visited by commands

Start ( ) : void

Starts the server listening for network connections

Stop ( ) : void
TcpServer ( IPAddress ip, int port ) : System

Méthodes protégées

Méthode Description
CreateConnection ( TcpClient client ) : CommandConnection

Creates a connection object from a TcpClient

Private Methods

Méthode Description
Listen ( object pars ) : void
OnClientConnected ( object connection ) : void

Handle clients connecting to the server by creating an AppInstance for the connection

Method Details

CreateConnection() protected méthode

Creates a connection object from a TcpClient
protected CreateConnection ( TcpClient client ) : CommandConnection
client System.Net.Sockets.TcpClient
Résultat Mycroft.App.CommandConnection

Issue() public méthode

Allow the server to be visited by commands
public Issue ( Command command ) : void
command Mycroft.Cmd.Command The command that will operate on the server
Résultat void

Start() public méthode

Starts the server listening for network connections
public Start ( ) : void
Résultat void

Stop() public méthode

public Stop ( ) : void
Résultat void

TcpServer() public méthode

public TcpServer ( IPAddress ip, int port ) : System
ip System.Net.IPAddress
port int
Résultat System