29#ifndef _TIMERFACTORY_H_
30#define _TIMERFACTORY_H_
55 Timer* timer =
nullptr;
75 SPX_MSG_ERROR(std::cerr <<
"wrong timer specified" << std::endl;)
84 if(ttype != timer->
type())
Class to create new timers and to switch types of exiting ones.
static Timer * switchTimer(Timer *timer, Timer::TYPE ttype)
static Timer * createTimer(Timer::TYPE ttype)
create timers and allocate memory for them
Wrapper for the system time query methods.
virtual TYPE type()=0
return type of timer
Everything should be within this namespace.
void spx_free(T &p)
Release memory.
void spx_alloc(T &p, int n=1)
Allocate memory.
Memory allocation routines.
Debugging, floating point type and parameter definitions.
#define SPX_MSG_ERROR(x)
Prints out message x if the verbosity level is at least SPxOut::ERROR.