An abstraction for a time stamp and/or sequence number. More...
#include <yarp/os/Stamp.h>
Inheritance diagram for yarp::os::Stamp:Public Member Functions | |
| Stamp () | |
| Construct an invalid Stamp. | |
| Stamp (int count, double time) | |
| Construct a Stamp with a given sequence number and time. | |
| int | getCount () const |
| Get the sequence number. | |
| double | getTime () const |
| Get the time stamp. | |
| bool | isValid () const |
| Check if this Stamp is valid. | |
| int | getMaxCount () const |
| Get the maximum sequence number, after which an incrementing sequence should return to zero. | |
| void | update () |
| Set the timestamp to the current time, and increment the sequence number (wrapping to 0 if the sequence number exceeds Stamp::getMaxCount()) | |
| void | update (double time) |
| Set the timestamp to a given time, and increments the sequence number (wrapping to 0 if the sequence exceeds Stamp::getMaxCount()) | |
Public Member Functions inherited from yarp::os::StampData | |
| StampData ()=default | |
| StampData (const std::int32_t sequenceNumber, const double timeStamp) | |
| bool | read (yarp::os::idl::WireReader &reader) override |
| bool | read (yarp::os::ConnectionReader &connection) override |
| Read this object from a network connection. | |
| bool | write (const yarp::os::idl::WireWriter &writer) const override |
| bool | write (yarp::os::ConnectionWriter &connection) const override |
| Write this object to a network connection. | |
| std::string | toString () const |
Public Member Functions inherited from yarp::os::idl::WirePortable | |
| virtual bool | readBare (yarp::os::ConnectionReader &reader) |
| virtual bool | writeBare (yarp::os::ConnectionWriter &writer) const |
| virtual bool | readBottle (yarp::os::ConnectionReader &reader) |
| virtual bool | writeBottle (yarp::os::ConnectionWriter &writer) const |
Public Member Functions inherited from yarp::os::Portable | |
| virtual Type | getType () const |
Public Member Functions inherited from yarp::os::PortReader | |
| virtual | ~PortReader () |
| Destructor. | |
| virtual Type | getReadType () const |
Public Member Functions inherited from yarp::os::PortWriter | |
| virtual | ~PortWriter () |
| Destructor. | |
| virtual void | onCompletion () const |
| This is called when the port has finished all writing operations. | |
| virtual void | onCommencement () const |
| This is called when the port is about to begin writing operations. | |
| virtual yarp::os::Type | getWriteType () const |
Additional Inherited Members | |
Public Types inherited from yarp::os::StampData | |
| typedef yarp::os::idl::Unwrapped< StampData > | unwrapped |
Static Public Member Functions inherited from yarp::os::Portable | |
| static bool | copyPortable (const PortWriter &writer, PortReader &reader) |
| Copy one portable to another, via writing and reading. | |
Protected Attributes inherited from yarp::os::StampData | |
| std::int32_t | sequenceNumber {0} |
| double | timeStamp {0.0} |
|
explicit |
| int yarp::os::Stamp::getCount | ( | ) | const |
| int yarp::os::Stamp::getMaxCount | ( | ) | const |
| double yarp::os::Stamp::getTime | ( | ) | const |
| bool yarp::os::Stamp::isValid | ( | ) | const |
| void yarp::os::Stamp::update | ( | ) |
Set the timestamp to the current time, and increment the sequence number (wrapping to 0 if the sequence number exceeds Stamp::getMaxCount())
Set the timestamp to a given time, and increments the sequence number (wrapping to 0 if the sequence exceeds Stamp::getMaxCount())