Shadowrun: Awakened 29 September 2011 - Build 871
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes
RakNet::PacketizedTCP Class Reference

#include <PacketizedTCP.h>

Inheritance diagram for RakNet::PacketizedTCP:

List of all members.

Public Member Functions

void AttachPlugin (PluginInterface2 *plugin)
void CloseConnection (SystemAddress systemAddress)
 Disconnects a player/address.
void DetachPlugin (PluginInterface2 *plugin)
SystemAddress HasCompletedConnectionAttempt (void)
SystemAddress HasFailedConnectionAttempt (void)
SystemAddress HasLostConnection (void)
 Queued events of lost connections.
SystemAddress HasNewIncomingConnection (void)
 Queued events of new incoming connections.
 PacketizedTCP ()
PacketReceive (void)
 Returns data received.
void Send (const char *data, unsigned length, const SystemAddress &systemAddress, bool broadcast)
 Sends a byte stream.
bool SendList (const char **data, const int *lengths, const int numParameters, const SystemAddress &systemAddress, bool broadcast)
bool Start (unsigned short port, unsigned short maxIncomingConnections, int threadPriority=-99999, unsigned short socketFamily=AF_INET)
void Stop (void)
 Stops the TCP server.
virtual ~PacketizedTCP ()

Static Public Member Functions

static void DestroyInstance (PacketizedTCP *i)
static PacketizedTCPGetInstance (void)

Protected Member Functions

void AddToConnectionList (const SystemAddress &sa)
void ClearAllConnections (void)
void PushNotificationsToQueues (void)
void RemoveFromConnectionList (const SystemAddress &sa)
PacketReturnOutgoingPacket (void)

Protected Attributes

DataStructures::Queue
< SystemAddress
_completedConnectionAttempts
DataStructures::Queue
< SystemAddress
_failedConnectionAttempts
DataStructures::Queue
< SystemAddress
_lostConnections
DataStructures::Queue
< SystemAddress
_newIncomingConnections
DataStructures::Map
< SystemAddress,
DataStructures::ByteQueue * > 
connections
DataStructures::List
< PluginInterface2 * > 
messageHandlerList
DataStructures::Queue< Packet * > waitingPackets

Detailed Description

Definition at line 22 of file PacketizedTCP.h.


Constructor & Destructor Documentation

RakNet::PacketizedTCP::PacketizedTCP ( )
virtual RakNet::PacketizedTCP::~PacketizedTCP ( ) [virtual]

Member Function Documentation

void RakNet::PacketizedTCP::AddToConnectionList ( const SystemAddress sa) [protected]
void RakNet::PacketizedTCP::AttachPlugin ( PluginInterface2 plugin)
void RakNet::PacketizedTCP::ClearAllConnections ( void  ) [protected]
void RakNet::PacketizedTCP::CloseConnection ( SystemAddress  systemAddress)

Reimplemented from RakNet::TCPInterface.

static void RakNet::PacketizedTCP::DestroyInstance ( PacketizedTCP i) [static]
void RakNet::PacketizedTCP::DetachPlugin ( PluginInterface2 plugin)
static PacketizedTCP* RakNet::PacketizedTCP::GetInstance ( void  ) [static]

Reimplemented from RakNet::TCPInterface.

SystemAddress RakNet::PacketizedTCP::HasCompletedConnectionAttempt ( void  )

Has a previous call to connect succeeded?

Returns:
UNASSIGNED_SYSTEM_ADDRESS = no. Anything else means yes.

Reimplemented from RakNet::TCPInterface.

SystemAddress RakNet::PacketizedTCP::HasFailedConnectionAttempt ( void  )

Has a previous call to connect failed?

Returns:
UNASSIGNED_SYSTEM_ADDRESS = no. Anything else means yes.

Reimplemented from RakNet::TCPInterface.

SystemAddress RakNet::PacketizedTCP::HasLostConnection ( void  )

Reimplemented from RakNet::TCPInterface.

SystemAddress RakNet::PacketizedTCP::HasNewIncomingConnection ( void  )

Reimplemented from RakNet::TCPInterface.

void RakNet::PacketizedTCP::PushNotificationsToQueues ( void  ) [protected]
Packet* RakNet::PacketizedTCP::Receive ( void  )

Reimplemented from RakNet::TCPInterface.

void RakNet::PacketizedTCP::RemoveFromConnectionList ( const SystemAddress sa) [protected]
Packet* RakNet::PacketizedTCP::ReturnOutgoingPacket ( void  ) [protected]
void RakNet::PacketizedTCP::Send ( const char *  data,
unsigned  length,
const SystemAddress systemAddress,
bool  broadcast 
)
bool RakNet::PacketizedTCP::SendList ( const char **  data,
const int *  lengths,
const int  numParameters,
const SystemAddress systemAddress,
bool  broadcast 
)
bool RakNet::PacketizedTCP::Start ( unsigned short  port,
unsigned short  maxIncomingConnections,
int  threadPriority = -99999,
unsigned short  socketFamily = AF_INET 
)

Starts the TCP server on the indicated port

Parameters:
[in]portWhich port to listen on.
[in]maxIncomingConnectionsMax incoming connections we will accept
[in]maxConnectionsMax total connections, which should be >= maxIncomingConnections
[in]threadPriorityPassed to the thread creation routine. Use THREAD_PRIORITY_NORMAL for Windows. For Linux based systems, you MUST pass something reasonable based on the thread priorities for your application.
[in]socketFamilyIP version: For IPV4, use AF_INET (default). For IPV6, use AF_INET6. To autoselect, use AF_UNSPEC.
void RakNet::PacketizedTCP::Stop ( void  )

Reimplemented from RakNet::TCPInterface.


Member Data Documentation

Definition at line 86 of file PacketizedTCP.h.

Definition at line 86 of file PacketizedTCP.h.

Definition at line 86 of file PacketizedTCP.h.

Definition at line 86 of file PacketizedTCP.h.

Definition at line 83 of file PacketizedTCP.h.

Definition at line 80 of file PacketizedTCP.h.

Definition at line 82 of file PacketizedTCP.h.


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

Copyright © 2007-2010 by The Shadowrun: Awakened Team. This work is licensed under the GNU Lesser General Public License 3.

GNU Lesser General Public License 3 Sourceforge.net