/* * WorldTime.hpp * * Created on: Feb 7, 2011 * Author: heber */ #ifndef WORLDTIME_HPP_ #define WORLDTIME_HPP_ // include config.h #ifdef HAVE_CONFIG_H #include #endif #include "CodePatterns/Singleton.hpp" class WorldTimeTest; class WorldTime : public Singleton { //!> unit test should be friend to access private variables friend class WorldTimeTest; //!> Make access to constructor and destructor possible from inside the singleton friend class Singleton; public: /** Setter for CurrentTime. * * @param _step value to set CurrentTime to */ void setTime(int _step); /** Getter for CurrentTime. * * @return CurrentTime */ int getTime() const; /** Setter for StepWidth. * * @param _step value to set StepWidth to */ void setStepWidth(double _width); /** Getter for StepWidth. * * @return StepWidth */ double getStepWidth() const; private: int CurrentTime; //!< contains current time step double StepWidth; //!< contains width of one time step in atomic units protected: /** * private constructor to ensure creation of the world using * the singleton pattern. */ WorldTime(); /** * private destructor to ensure destruction of the world using the * singleton pattern. */ ~WorldTime(); }; #endif /* WORLDTIME_HPP_ */