SimulationHolder Class Reference

Singleton class that gives current simulation parameters. More...

#include <Simulation.h>

Inheritance diagram for SimulationHolder:

Inheritance graph
[legend]

List of all members.

Public Member Functions

Simulationget ()
template<class T >
T * get ()
 Convinience method that casts the Simulation object into the corresponding T class (with a boost::polymorphic_downcast<>).
void set (Simulation *pObj)
 Sets the current game.

Protected Attributes

SimulationpObj


Detailed Description

Singleton class that gives current simulation parameters.

Definition at line 145 of file Simulation.h.


Member Function Documentation

template<class T >
T* SimulationHolder::get (  )  [inline]

Convinience method that casts the Simulation object into the corresponding T class (with a boost::polymorphic_downcast<>).

Definition at line 151 of file Simulation.h.

References pObj.

Simulation* SimulationHolder::get (  )  [inline]

Definition at line 147 of file Simulation.h.

References pObj.

Referenced by Ammo::hitBefore().

void SimulationHolder::set ( Simulation pObj  )  [inline]

Sets the current game.

Warning:
This function MUST be called either on app initialisation, or when all threads (3D/Physics/Networking...) have ended their current loop.
Todo:
must be thread safe.

Definition at line 156 of file Simulation.h.

References pObj.


Member Data Documentation

Definition at line 159 of file Simulation.h.

Referenced by get(), and set().


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

Generated on Sun Jan 17 11:39:29 2010 for PVLE (Pro-Vocation Light Engine) by  doxygen 1.5.9