C# Class LLApiServer

Inheritance: IDisposable
ファイルを表示 Open project: buronix/LLApi-Basic-Implementation Class Usage Examples

Public Methods

Method Description
Dispose ( ) : void
LLApiServer ( GameServer, gameServer, int port, ushort maxConnections, ushort maxMessages ) : UnityEngine.Networking
Listen ( ) : void
RegisterHandler ( Subjects, subject, SubjectDelegate handler ) : void
RemoveHandler ( Subjects, subject, SubjectDelegate handler ) : bool
SendMessage ( int connectionId, NetworkWriter writer, NetworkError &Error ) : bool
SendMessage ( int connectionId, NetworkWriter writer, int channel, NetworkError &Error ) : bool
SendOutputMessages ( ) : void
Start ( ) : void
Stop ( ) : void
TryGetConnection ( int connectionId, LLApiConnection, &connection ) : bool
addOutPutMessageToQueue ( OutputMessage, message ) : void

Private Methods

Method Description
ManageOutputMessage ( OutputMessage, message ) : ushort
MessagesConsumer ( ) : void
addConnection ( LLApiConnection, connection ) : void
addInputMessageToQueue ( InputMessage, message ) : void
removeConnection ( int connectionId ) : bool

Method Details

Dispose() public method

public Dispose ( ) : void
return void

LLApiServer() public method

public LLApiServer ( GameServer, gameServer, int port, ushort maxConnections, ushort maxMessages ) : UnityEngine.Networking
gameServer GameServer,
port int
maxConnections ushort
maxMessages ushort
return UnityEngine.Networking

Listen() public method

public Listen ( ) : void
return void

RegisterHandler() public method

public RegisterHandler ( Subjects, subject, SubjectDelegate handler ) : void
subject Subjects,
handler SubjectDelegate
return void

RemoveHandler() public method

public RemoveHandler ( Subjects, subject, SubjectDelegate handler ) : bool
subject Subjects,
handler SubjectDelegate
return bool

SendMessage() public method

public SendMessage ( int connectionId, NetworkWriter writer, NetworkError &Error ) : bool
connectionId int
writer UnityEngine.Networking.NetworkWriter
Error NetworkError
return bool

SendMessage() public method

public SendMessage ( int connectionId, NetworkWriter writer, int channel, NetworkError &Error ) : bool
connectionId int
writer UnityEngine.Networking.NetworkWriter
channel int
Error NetworkError
return bool

SendOutputMessages() public method

public SendOutputMessages ( ) : void
return void

Start() public method

public Start ( ) : void
return void

Stop() public method

public Stop ( ) : void
return void

TryGetConnection() public method

public TryGetConnection ( int connectionId, LLApiConnection, &connection ) : bool
connectionId int
connection LLApiConnection,
return bool

addOutPutMessageToQueue() public method

public addOutPutMessageToQueue ( OutputMessage, message ) : void
message OutputMessage,
return void