#include <timeStamp.h>
Public Member Functions |
|
|
Constructors and Destructors.
|
|
| PreciseTime () | |
| Default constructor. |
|
| PreciseTime (const PreciseTime &time) | |
| Copy constructor. |
|
| PreciseTime (long secs, long usecs) | |
| Detailed constructor. |
|
| virtual | ~PreciseTime () |
| Destructor. |
|
|
Assignment
|
|
| void | set (long secs, long usecs) |
| Assignment method. |
|
| void | set (const PreciseTime &time) |
| Assignment method. |
|
| const PreciseTime & | operator= (const PreciseTime &time) |
| Assignment operator. |
|
| virtual void | clear () |
| Clear method. |
|
|
Predicates
|
|
| bool | operator< (const PreciseTime &time) const |
| Greater than operator. |
|
| bool | operator> (const PreciseTime &time) const |
| Lesser than operator. |
|
| bool | operator== (const PreciseTime &time) const |
| Equality operator. |
|
|
Storable interface.
|
|
| void | write (PersistenceManager &pm) const |
| Persistent stream writing. |
|
| bool | read (PersistenceManager &pm) |
| Persistent stream reading. |
|
Static Public Attributes |
|
|
Constants.
|
|
| static const PreciseTime | ZERO |
| Zero object. |
|
Protected Attributes |
|
| long | secs_ |
| long | usecs_ |
Accessors |
|
| long | getSeconds () const |
| Return the seconds since Jan.
|
|
| long | getMicroSeconds () const |
| Return the microseconds. |
|
| static PreciseTime | now () |
| Return the current time. |
|
Used to store a point of time. This class provides a higher precision than Time (below seconds).
Storable| BALL::PreciseTime::PreciseTime | ( | ) |
Default constructor.
Initialize with zero.
| long BALL::PreciseTime::getSeconds | ( | ) | const |
Return the seconds since Jan.
1, 1970.
| static PreciseTime BALL::PreciseTime::now | ( | ) | [static] |
Return the current time.
| bool BALL::PreciseTime::read | ( | PersistenceManager & | pm | ) |
Persistent stream reading.
This method reads the contents of a PreciseTime object from
the persistent stream using the readPrimitive
method of the PersistenceManager.
| pm | the persistence manager |
| void BALL::PreciseTime::write | ( | PersistenceManager & | pm | ) | const |
Persistent stream writing.
This method writes the contents of the PreciseTime
objects to the persistent stream using the
writePrimitive method of the PersistenceManager.
| pm | the persistence manager |
1.5.8