C# Class GlowCommon.DiscoveryServer

Show file Open project: QuinnDamerell/Glow Class Usage Examples

Public Methods

Method Description
DiscoveryServer ( DiscoveryMode mode ) : GlowCommon.Interfaces
DoWork ( uint timeElaspedMs ) : void
InvokeBroadcast ( ) : System.Threading.Tasks.Task

Can be called by the client to try to send a message to the server to broadcast.

SetListener ( IDiscoveryServerListener listener ) : void

Used to set a listener for broadcast messages.

Private Methods

Method Description
DataSocket_MessageRecieved ( DatagramSocket sender, DatagramSocketMessageReceivedEventArgs args ) : void

Fired when a message is received on the socket

SendBroadcast ( ) : void
SendMessage ( string message ) : System.Threading.Tasks.Task

Send a message on the socket

Method Details

DiscoveryServer() public method

public DiscoveryServer ( DiscoveryMode mode ) : GlowCommon.Interfaces
mode DiscoveryMode
return GlowCommon.Interfaces

DoWork() public method

public DoWork ( uint timeElaspedMs ) : void
timeElaspedMs uint
return void

InvokeBroadcast() public method

Can be called by the client to try to send a message to the server to broadcast.
public InvokeBroadcast ( ) : System.Threading.Tasks.Task
return System.Threading.Tasks.Task

SetListener() public method

Used to set a listener for broadcast messages.
public SetListener ( IDiscoveryServerListener listener ) : void
listener IDiscoveryServerListener
return void