Orxonox  0.0.5 Codename: Arcturus
Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | List of all members
orxonox::ClientConnection Class Referenceabstract

#include </home/jenkins/workspace/orxonox_doxygen_trunk/src/libraries/network/ClientConnection.h>

Inheritance diagram for orxonox::ClientConnection:
orxonox::Connection orxonox::Client

Public Member Functions

 ClientConnection ()
 
virtual ~ClientConnection ()
 
void addPacket (ENetPacket *packet, uint8_t channelID)
 
virtual bool closeConnection ()
 
virtual bool establishConnection ()
 
bool isConnected ()
 
void setPort (unsigned int port)
 
void setServerAddress (const std::string &serverAddress)
 
- Public Member Functions inherited from orxonox::Connection
virtual ~Connection ()
 Destructor. More...
 

Protected Member Functions

virtual void connectionClosed ()=0
 
uint32_t getRTT ()
 
- Protected Member Functions inherited from orxonox::Connection
 Connection (uint32_t firstPeerID=NETWORK_PEER_ID_SERVER+1)
 Constructor. More...
 
void addPacket (ENetPacket *packet, uint32_t peerID, uint8_t channelID)
 Send a packet. More...
 
void broadcastPacket (ENetPacket *packet, uint8_t channelID)
 Send a broadcast packet. More...
 
void disconnectPeer (uint32_t peerID)
 Send an outgoing event of type 'disconnectPeer'. More...
 
void disconnectPeers ()
 Send an outgoing event of type 'disconnectPeers'. More...
 
void disconnectPeersInternal ()
 
void enableCompression ()
 
incomingEvent preprocessConnectEvent (ENetEvent &event)
 
incomingEvent preprocessDisconnectEvent (ENetEvent &event)
 
incomingEvent preprocessReceiveEvent (ENetEvent &event)
 
void processIncomingEvent (ENetEvent &event)
 Handle an incoming event. More...
 
void processOutgoingEvent (outgoingEvent &event)
 Send an event. More...
 
virtual void processPacket (packet::Packet *packet)=0
 
void processQueue ()
 
void startCommunicationThread ()
 Start the main communication thread. More...
 
void stopCommunicationThread ()
 Stop the main communication thread. More...
 
void waitOutgoingQueue ()
 

Private Member Functions

virtual void addPeer (uint32_t peerID) override
 
bool disconnectConnection ()
 
virtual void removePeer (uint32_t peerID) override
 

Private Attributes

bool established_
 
ENetPeerserver_
 
ENetAddressserverAddress_
 

Additional Inherited Members

- Protected Attributes inherited from orxonox::Connection
ENetHosthost_
 

Constructor & Destructor Documentation

orxonox::ClientConnection::ClientConnection ( )
orxonox::ClientConnection::~ClientConnection ( )
virtual

Member Function Documentation

void orxonox::ClientConnection::addPacket ( ENetPacket packet,
uint8_t  channelID 
)
void orxonox::ClientConnection::addPeer ( uint32_t  peerID)
overrideprivatevirtual

Implements orxonox::Connection.

bool orxonox::ClientConnection::closeConnection ( )
virtual

Reimplemented in orxonox::Client.

virtual void orxonox::ClientConnection::connectionClosed ( )
protectedpure virtual

Implemented in orxonox::Client.

bool orxonox::ClientConnection::disconnectConnection ( )
private
bool orxonox::ClientConnection::establishConnection ( )
virtual

Reimplemented in orxonox::Client.

uint32_t orxonox::ClientConnection::getRTT ( )
protected
bool orxonox::ClientConnection::isConnected ( )
inline
void orxonox::ClientConnection::removePeer ( uint32_t  peerID)
overrideprivatevirtual

Implements orxonox::Connection.

void orxonox::ClientConnection::setPort ( unsigned int  port)
void orxonox::ClientConnection::setServerAddress ( const std::string &  serverAddress)

Member Data Documentation

bool orxonox::ClientConnection::established_
private
ENetPeer* orxonox::ClientConnection::server_
private
ENetAddress* orxonox::ClientConnection::serverAddress_
private

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