Photon Server API
Public Member Functions | Properties | Events | List of all members
ExitGames.Net.Sockets.Pgm.PgmListener Class Reference

The PGM listener receives PGM messages from one or more network interfaces. This class is used internally by the PgmReceiver. More...

Inheritance diagram for ExitGames.Net.Sockets.Pgm.PgmListener:

Public Member Functions

 PgmListener (IPEndPoint endPoint)
 Initializes a new instance of the PgmListener class. More...
 
 PgmListener (IPAddress address, int port)
 Initializes a new instance of the PgmListener class. More...
 
 PgmListener (string address, int port)
 Initializes a new instance of the PgmListener class. More...
 
void Start ()
 Starts the listening. More...
 
void Stop ()
 Stops the listening and closes the socket. More...
 
void Dispose ()
 Disposes the listener. More...
 

Properties

bool IsRunning [get]
 Gets a value indicating whether the listener is running. More...
 
IPEndPoint LocalEndPoint [get]
 Gets an IPEndPoint that contains the local IP address and port number on which the PgmListener will listen for new connections. More...
 
int ReceiveBufferSize [get, set]
 Gets or sets the size in bytes of the receive buffer of the System.Net.Sockets.Socket. More...
 
IPAddressCollection ReceiveInterfaces [get]
 Gets the list of interfaces that the instance receives messages from. If no interface is specified the first local interface enumerated is used. More...
 
bool ReuseAddress [get, set]
 Gets or sets a value indicating whether the receiver socket is allowed to be bound to an address that is already in use. More...
 
bool UseHighSpeedIntranet [get, set]
 Gets or sets a value indicating whether a high bandwidth LAN (100Mbps+) connection is used. More...
 

Events

EventHandler< SocketAsyncEventArgs > AcceptSocket
 The accept socket event. More...
 

Detailed Description

The PGM listener receives PGM messages from one or more network interfaces. This class is used internally by the PgmReceiver.

Constructor & Destructor Documentation

ExitGames.Net.Sockets.Pgm.PgmListener.PgmListener ( IPEndPoint  endPoint)
inline

Initializes a new instance of the PgmListener class.

Parameters
endPointThe multicast end point.
ExitGames.Net.Sockets.Pgm.PgmListener.PgmListener ( IPAddress  address,
int  port 
)
inline

Initializes a new instance of the PgmListener class.

Parameters
addressThe multicast address.
portThe port.
ExitGames.Net.Sockets.Pgm.PgmListener.PgmListener ( string  address,
int  port 
)
inline

Initializes a new instance of the PgmListener class.

Parameters
addressThe multicast address.
portThe port.

Member Function Documentation

void ExitGames.Net.Sockets.Pgm.PgmListener.Dispose ( )
inline

Disposes the listener.

void ExitGames.Net.Sockets.Pgm.PgmListener.Start ( )
inline

Starts the listening.

Exceptions
InvalidOperationExceptionAlready running.
SocketExceptionException from the underlying Socket.
void ExitGames.Net.Sockets.Pgm.PgmListener.Stop ( )
inline

Stops the listening and closes the socket.

Property Documentation

bool ExitGames.Net.Sockets.Pgm.PgmListener.IsRunning
get

Gets a value indicating whether the listener is running.

True if listening, otherwise false.

IPEndPoint ExitGames.Net.Sockets.Pgm.PgmListener.LocalEndPoint
get

Gets an IPEndPoint that contains the local IP address and port number on which the PgmListener will listen for new connections.

The local IPEndPoint.

int ExitGames.Net.Sockets.Pgm.PgmListener.ReceiveBufferSize
getset

Gets or sets the size in bytes of the receive buffer of the System.Net.Sockets.Socket.

The default value is 128 KB.

IPAddressCollection ExitGames.Net.Sockets.Pgm.PgmListener.ReceiveInterfaces
get

Gets the list of interfaces that the instance receives messages from. If no interface is specified the first local interface enumerated is used.

An IPAddressCollection that contains the IPs of all listening interfaces.

bool ExitGames.Net.Sockets.Pgm.PgmListener.ReuseAddress
getset

Gets or sets a value indicating whether the receiver socket is allowed to be bound to an address that is already in use.

Default is true.

bool ExitGames.Net.Sockets.Pgm.PgmListener.UseHighSpeedIntranet
getset

Gets or sets a value indicating whether a high bandwidth LAN (100Mbps+) connection is used.

Default is true.

Event Documentation

EventHandler<SocketAsyncEventArgs> ExitGames.Net.Sockets.Pgm.PgmListener.AcceptSocket

The accept socket event.