OpenZWave Library: OpenZWave::TimeStamp Class Reference

| OpenZWave Library 1.6.0

Loading...
Searching...
No Matches
Public Member Functions | List of all members
OpenZWave::TimeStamp Class Reference
Platform Abstraction Support

Implements a platform-independent TimeStamp. More...

`#include <TimeStamp.h>`

## Public Member Functions
| TimeStamp ()
| ~TimeStamp ()
void | SetTime (int32 _milliseconds=0)
int32 | TimeRemaining ()
string | GetAsString ()
int32 | operator- (TimeStamp const &_other)

## Detailed Description

Implements a platform-independent TimeStamp.

## Constructor & Destructor Documentation

## ◆ TimeStamp()

TimeStamp::TimeStamp | ( |  | ) |

Constructor. Creates a TimeStamp object.

## ◆ ~TimeStamp()

TimeStamp::~TimeStamp | ( |  | ) |

Destructor. Destroys the TimeStamp object.

## Member Function Documentation

## ◆ GetAsString()

string TimeStamp::GetAsString | ( |  | ) |

Return as a string for output.

Returns
  string

## ◆ operator-()

int32 TimeStamp::operator- | ( | TimeStamp const & | _other | ) |

Overload the subtract operator to get the difference between two timestamps in milliseconds.

## ◆ SetTime()

void TimeStamp::SetTime | ( | int32 | _milliseconds = `0` | ) |

SetTime. Sets the timestamp to now, plus the offset in milliseconds.

Parameters

  _milliseconds | optional positive or negative offset from now in milliseconds. Defaults to zero.

## ◆ TimeRemaining()

int32 TimeStamp::TimeRemaining | ( |  | ) |

TimeRemaining. Gets the difference between now and the timestamp time in milliseconds.

Returns
  milliseconds remaining until we reach the timestamp. The return value is negative if the timestamp is in the past.

The documentation for this class was generated from the following files:

- TimeStamp.h
- TimeStamp.cpp