Time handling...
More...
#include <msec.h>
Time handling...
Definition at line 70 of file msec.h.
◆ msec() [1/3]
Constructor, sets the time to the current system time.
Definition at line 76 of file msec.h.
◆ msec() [2/3]
msec::msec |
( |
const msec & |
in_msec | ) |
|
|
inline |
Constructor using another msec object.
- Parameters
-
in_msec | - Time for this object |
Definition at line 83 of file msec.h.
◆ msec() [3/3]
msec::msec |
( |
const int |
sec, |
|
|
const int |
milsec |
|
) |
| |
|
inline |
Constructor using seconds and milli sconds.
- Parameters
-
sec | - Seconds |
milsec | - Milli seconds |
Definition at line 91 of file msec.h.
◆ get_printable()
const char* msec::get_printable |
( |
| ) |
const |
Return the time as printable string.
◆ GetDelta()
void msec::GetDelta |
( |
const msec & |
future, |
|
|
timeval & |
timeout |
|
) |
| const |
Get the difference between this and the given time.
If future is before this objects time, "timeout" will be set to zero.
- Parameters
-
future | - Time to compare to |
timeout | - Will be filled with the difference |
Referenced by GetDeltaFromNow().
◆ GetDeltaFromNow()
void msec::GetDeltaFromNow |
( |
timeval & |
timeout | ) |
const |
|
inline |
Get the difference between this object and the current system time.
If the system time is before this objects time, "timeout" will be set to zero.
- Parameters
-
timeout | - Will be filled with the difference |
Definition at line 154 of file msec.h.
References GetDelta().
◆ IsInfinite()
int msec::IsInfinite |
( |
| ) |
const |
|
inline |
Check if the time is infinite.
- Returns
- True, if the time is infinite.
Definition at line 135 of file msec.h.
◆ operator unsigned long()
msec::operator unsigned long |
( |
| ) |
const |
|
inline |
Use as an unsigned long.
- Returns
- Time in milli seconds
Definition at line 116 of file msec.h.
◆ operator+=() [1/2]
msec& msec::operator+= |
( |
const long |
millisec | ) |
|
◆ operator+=() [2/2]
msec& msec::operator+= |
( |
const timeval & |
t1 | ) |
|
◆ operator-=() [1/2]
msec& msec::operator-= |
( |
const long |
millisec | ) |
|
◆ operator-=() [2/2]
msec& msec::operator-= |
( |
const timeval & |
t1 | ) |
|
◆ operator=() [1/2]
◆ operator=() [2/2]
msec& msec::operator= |
( |
const timeval & |
t1 | ) |
|
◆ refresh()
Set the time to the current system time.
◆ SetInfinite()
void msec::SetInfinite |
( |
| ) |
|
|
inline |
Set the object out into the future as far as possible.
Definition at line 127 of file msec.h.
◆ operator!=
◆ operator<
◆ operator<=
◆ operator==
◆ operator>
◆ operator>=
◆ m_changed
◆ m_localtime_mutex
◆ m_output_buffer
◆ m_time
The documentation for this class was generated from the following file: