Base class for Duration implementations. Provides storage, common functions and operator overloads. This should not need to be used directly. More...
#include <duration.h>
Public Member Functions | |
DurationBase () | |
DurationBase (int32_t _sec, int32_t _nsec) | |
DurationBase (double t) | |
T & | fromNSec (int64_t t) |
T & | fromSec (double t) |
bool | isZero () const |
bool | operator!= (const T &rhs) const |
T | operator* (double scale) const |
T & | operator*= (double scale) |
T | operator+ (const T &rhs) const |
T & | operator+= (const T &rhs) |
T | operator- (const T &rhs) const |
T | operator- () const |
T & | operator-= (const T &rhs) |
bool | operator< (const T &rhs) const |
bool | operator<= (const T &rhs) const |
bool | operator== (const T &rhs) const |
bool | operator> (const T &rhs) const |
bool | operator>= (const T &rhs) const |
boost::posix_time::time_duration | toBoost () const |
int64_t | toNSec () const |
double | toSec () const |
~DurationBase () | |
Public Attributes | |
int32_t | nsec |
int32_t | sec |
Base class for Duration implementations. Provides storage, common functions and operator overloads. This should not need to be used directly.
Definition at line 72 of file duration.h.
|
inline |
Definition at line 76 of file duration.h.
ros::DurationBase< T >::DurationBase | ( | int32_t | _sec, |
int32_t | _nsec | ||
) |
Definition at line 47 of file impl/duration.h.
|
inlineexplicit |
Definition at line 78 of file duration.h.
|
inline |
Definition at line 79 of file duration.h.
T & ros::DurationBase< T >::fromNSec | ( | int64_t | t | ) |
Definition at line 68 of file impl/duration.h.
T & ros::DurationBase< T >::fromSec | ( | double | t | ) |
Definition at line 54 of file impl/duration.h.
bool ros::DurationBase< T >::isZero | ( | ) | const |
Definition at line 176 of file impl/duration.h.
|
inline |
Definition at line 88 of file duration.h.
T ros::DurationBase< T >::operator* | ( | double | scale | ) | const |
Definition at line 89 of file impl/duration.h.
T & ros::DurationBase< T >::operator*= | ( | double | scale | ) |
Definition at line 123 of file impl/duration.h.
T ros::DurationBase< T >::operator+ | ( | const T & | rhs | ) | const |
Definition at line 82 of file impl/duration.h.
T & ros::DurationBase< T >::operator+= | ( | const T & | rhs | ) |
Definition at line 109 of file impl/duration.h.
T ros::DurationBase< T >::operator- | ( | const T & | rhs | ) | const |
Definition at line 95 of file impl/duration.h.
T ros::DurationBase< T >::operator- | ( | ) | const |
Definition at line 102 of file impl/duration.h.
T & ros::DurationBase< T >::operator-= | ( | const T & | rhs | ) |
Definition at line 116 of file impl/duration.h.
bool ros::DurationBase< T >::operator< | ( | const T & | rhs | ) | const |
Definition at line 130 of file impl/duration.h.
bool ros::DurationBase< T >::operator<= | ( | const T & | rhs | ) | const |
Definition at line 150 of file impl/duration.h.
bool ros::DurationBase< T >::operator== | ( | const T & | rhs | ) | const |
Definition at line 170 of file impl/duration.h.
bool ros::DurationBase< T >::operator> | ( | const T & | rhs | ) | const |
Definition at line 140 of file impl/duration.h.
bool ros::DurationBase< T >::operator>= | ( | const T & | rhs | ) | const |
Definition at line 160 of file impl/duration.h.
boost::posix_time::time_duration ros::DurationBase< T >::toBoost | ( | ) | const |
Definition at line 183 of file impl/duration.h.
|
inline |
Definition at line 94 of file duration.h.
|
inline |
Definition at line 93 of file duration.h.
int32_t ros::DurationBase< T >::nsec |
Definition at line 75 of file duration.h.
int32_t ros::DurationBase< T >::sec |
Definition at line 75 of file duration.h.