Artemus::Proxy::ServerConnection Class Reference

Handler for the server System Link connection. More...

List of all members.

Public Member Functions

void CloseConnection ()
 Closes the connection to the server.
void NewMessage (ServerMessage message)
 Handler for incoming server messages from a client.
void OpenConnection ()
 Opens the connection to the server.
 ServerConnection ()
 Constructs a new server connection instance.

Properties

bool IsConnected [get]
 Gets the connection status of the server.
string StatusString [get]
 Gets a string representing the server connection status.

Private Member Functions

void FindSessionCallback (IAsyncResult result)
 Async callback for System Link session found events.
void SessionEndedHandler (object sender, NetworkSessionEndedEventArgs args)
 Handles session ended events.
void ThreadProc ()
 The processing thread entry point.

Private Attributes

IAsyncResult m_findSessionResult = null
const int m_maxOutstanding = 2
NetworkSession m_networkSession = null
int m_outstandingRequests = 0
Queue< ServerMessagem_packetInQueue = null
Queue< ServerMessagem_packetOutQueue = null
Mutex m_packetOutQueueMutex = null
string m_statusString = null
Thread m_thread = null
ManualResetEvent m_threadExitEvent = null


Detailed Description

Handler for the server System Link connection.


Constructor & Destructor Documentation

Artemus::Proxy::ServerConnection::ServerConnection (  )  [inline]

Constructs a new server connection instance.


Member Function Documentation

void Artemus::Proxy::ServerConnection::CloseConnection (  )  [inline]

Closes the connection to the server.

void Artemus::Proxy::ServerConnection::FindSessionCallback ( IAsyncResult  result  )  [inline, private]

Async callback for System Link session found events.

Parameters:
result The IAsyncResult object of the callback.

void Artemus::Proxy::ServerConnection::NewMessage ( ServerMessage  message  )  [inline]

Handler for incoming server messages from a client.

Parameters:
message The ServerMessage instance of the message.

void Artemus::Proxy::ServerConnection::OpenConnection (  )  [inline]

Opens the connection to the server.

void Artemus::Proxy::ServerConnection::SessionEndedHandler ( object  sender,
NetworkSessionEndedEventArgs  args 
) [inline, private]

Handles session ended events.

Parameters:
sender The sending object.
args The event arguments.

void Artemus::Proxy::ServerConnection::ThreadProc (  )  [inline, private]

The processing thread entry point.

Here is the call graph for this function:


Member Data Documentation

NetworkSession Artemus::Proxy::ServerConnection::m_networkSession = null [private]

ManualResetEvent Artemus::Proxy::ServerConnection::m_threadExitEvent = null [private]


Property Documentation

bool Artemus::Proxy::ServerConnection::IsConnected [get]

Gets the connection status of the server.

string Artemus::Proxy::ServerConnection::StatusString [get]

Gets a string representing the server connection status.


The documentation for this class was generated from the following file:

Generated on Sat Jul 19 14:22:34 2008 for Artemus Proxy by  doxygen 1.5.5