#include <TimeValue.h>
Public Member Functions | |
| TimeValue (long sec=0, long usec=0) | |
| Constructor. | |
| TimeValue (double timeval) | |
| long int | sec () const |
| long int | usec () const |
| TimeValue | operator- (TimeValue &tm) |
| Time subtraction. | |
| TimeValue | operator+ (TimeValue &tm) |
| Time addition. | |
| TimeValue | operator= (double time) |
| Convert double type into time type. | |
| operator double () const | |
| Convert time type into double type. | |
| int | sign () const |
| Sign judgment. | |
| void | normalize () |
| Normalize. | |
| coil::TimeValue::TimeValue | ( | long | sec = 0, |
|
| long | usec = 0 | |||
| ) |
Constructor.
Constructor Initialize with the specified second and micro second.
| sec | Second(The default value:0) | |
| usec | Micro second(The default value:0) |
| coil::TimeValue::TimeValue | ( | double | timeval | ) |
| long int coil::TimeValue::sec | ( | ) | const [inline] |
Referenced by RTC::RingBuffer< DataType >::read(), setTimestamp(), coil::sleep(), and RTC::RingBuffer< DataType >::write().
| long int coil::TimeValue::usec | ( | ) | const [inline] |
Referenced by RTC::RingBuffer< DataType >::read(), setTimestamp(), coil::sleep(), and RTC::RingBuffer< DataType >::write().
Time subtraction.
Subtract the time given by the argument from the set time.
| tm | Subtracted time |
Time addition.
Add the time given by the argument to the set time.
| tm | Added time |
| TimeValue coil::TimeValue::operator= | ( | double | time | ) |
Convert double type into time type.
Convert double type given by the argument into time type.
| time | the original value |
| coil::TimeValue::operator double | ( | ) | const |
Convert time type into double type.
Convert held information into double type.
| int coil::TimeValue::sign | ( | ) | const |
Sign judgment.
Judge sign of the held contents
| void coil::TimeValue::normalize | ( | ) |
Normalize.
Normalize the value expression into a canonical form.
1.5.5