#include <timesource.h>
Inheritance diagram for fawkes::TimeSource:
Public Member Functions | |
virtual | ~TimeSource () |
Destructor. | |
virtual void | get_time (timeval *tv) const =0 |
Get the current time. | |
virtual timeval | conv_to_realtime (const timeval *tv) const =0 |
Convert a time given w.r.t. |
This interfaces describes a way to interact with time sources that can be given to a Clock (for instance for simulation environments).
Definition at line 36 of file timesource.h.
virtual fawkes::TimeSource::~TimeSource | ( | ) | [inline, virtual] |
virtual timeval fawkes::TimeSource::conv_to_realtime | ( | const timeval * | tv | ) | const [pure virtual] |
Convert a time given w.r.t.
this time sources into system time.
tv | the time to convert |
Implemented in fawkes::SimulatorTimeSource.
Referenced by fawkes::Clock::ext_to_realtime().
virtual void fawkes::TimeSource::get_time | ( | timeval * | tv | ) | const [pure virtual] |
Get the current time.
tv | the current time is written to this timeval |
Implemented in fawkes::SimulatorTimeSource.
Referenced by fawkes::Clock::get_time().