YAPOG  0.0.1
Yet Another Pokemon Online Game
yse::Server Class Reference

#include <Server.hpp>

Collaboration diagram for yse::Server:

List of all members.

Public Member Functions

 Server ()
void Init ()
void Launch ()
void Stop ()

Private Member Functions

 DISALLOW_COPY (Server)
void AddClient (ClientSession *client)
void HandleListening ()
void Dispose ()
void InitRandom ()
void InitContentManager (const yap::Path &contentRootPath)
void InitObjectFactory ()
void InitWorldObjectStateFactory ()
void InitLoggerManager ()
void LoadMaps ()

Private Attributes

bool isRunning_
yap::ServerSocket socket_
yap::Mutex socketMutex_
yap::Thread listeningThread_
yap::Int16 port_
ClientManager clients_
yap::Mutex clientsMutex_
World world_
yap::Mutex worldMutex_
yap::Timer worldUpdateTimer_
yap::ContentManagercontentManager_
yap::ObjectFactoryobjectFactory_
yap::WorldObjectStateFactoryworldObjectStateFactory_
yap::Loggerlogger_
yap::DatabaseManager databaseManager_
yap::Mutex databaseManagerMutex_

Static Private Attributes

static const bool DEFAULT_RUNNING_STATE = false
static const yap::Int16 DEFAULT_PORT = 8008
static const float DEFAULT_WORLD_UPDATE_RATE = 100.0f

Detailed Description

Definition at line 29 of file Server.hpp.


Constructor & Destructor Documentation

yse::Server::Server ( )

Definition at line 48 of file Server.cpp.

Here is the call graph for this function:


Member Function Documentation

void yse::Server::AddClient ( ClientSession client)
private

Definition at line 140 of file Server.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

yse::Server::DISALLOW_COPY ( Server  )
private
void yse::Server::Dispose ( )
private

Definition at line 133 of file Server.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void yse::Server::HandleListening ( )
private

Definition at line 160 of file Server.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void yse::Server::Init ( )

Definition at line 68 of file Server.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void yse::Server::InitContentManager ( const yap::Path contentRootPath)
private

Definition at line 185 of file Server.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void yse::Server::InitLoggerManager ( )
private

Definition at line 268 of file Server.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void yse::Server::InitObjectFactory ( )
private

Definition at line 190 of file Server.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void yse::Server::InitRandom ( )
private

Definition at line 180 of file Server.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void yse::Server::InitWorldObjectStateFactory ( )
private

Definition at line 262 of file Server.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void yse::Server::Launch ( )

Definition at line 94 of file Server.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void yse::Server::LoadMaps ( )
private

Definition at line 274 of file Server.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void yse::Server::Stop ( )

Definition at line 128 of file Server.cpp.


Member Data Documentation

ClientManager yse::Server::clients_
private

Definition at line 70 of file Server.hpp.

yap::Mutex yse::Server::clientsMutex_
private

Definition at line 71 of file Server.hpp.

yap::ContentManager& yse::Server::contentManager_
private

Definition at line 77 of file Server.hpp.

yap::DatabaseManager yse::Server::databaseManager_
private

Definition at line 83 of file Server.hpp.

yap::Mutex yse::Server::databaseManagerMutex_
private

Definition at line 84 of file Server.hpp.

const yap::Int16 yse::Server::DEFAULT_PORT = 8008
staticprivate

Definition at line 59 of file Server.hpp.

const bool yse::Server::DEFAULT_RUNNING_STATE = false
staticprivate

Definition at line 58 of file Server.hpp.

const float yse::Server::DEFAULT_WORLD_UPDATE_RATE = 100.0f
staticprivate

Definition at line 61 of file Server.hpp.

bool yse::Server::isRunning_
private

Definition at line 63 of file Server.hpp.

yap::Thread yse::Server::listeningThread_
private

Definition at line 66 of file Server.hpp.

yap::Logger& yse::Server::logger_
private

Definition at line 82 of file Server.hpp.

yap::ObjectFactory& yse::Server::objectFactory_
private

Definition at line 79 of file Server.hpp.

yap::Int16 yse::Server::port_
private

Definition at line 68 of file Server.hpp.

yap::ServerSocket yse::Server::socket_
private

Definition at line 64 of file Server.hpp.

yap::Mutex yse::Server::socketMutex_
private

Definition at line 65 of file Server.hpp.

World yse::Server::world_
private

Definition at line 73 of file Server.hpp.

yap::Mutex yse::Server::worldMutex_
private

Definition at line 74 of file Server.hpp.

yap::WorldObjectStateFactory& yse::Server::worldObjectStateFactory_
private

Definition at line 80 of file Server.hpp.

yap::Timer yse::Server::worldUpdateTimer_
private

Definition at line 75 of file Server.hpp.


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