added Clock::raw(); style fixes

This commit is contained in:
Guenter Obiltschnig 2014-10-08 07:59:48 +02:00
parent 9ee4d0a36b
commit ef34c21e91
2 changed files with 19 additions and 3 deletions

View File

@ -87,6 +87,13 @@ public:
/// since the system-specific epoch time (usually system
/// startup).
ClockVal raw() const;
/// Returns the clock value expressed in microseconds
/// since the system-specific epoch time (usually system
/// startup).
///
/// Same as microseconds().
ClockDiff elapsed() const;
/// Returns the time elapsed since the time denoted by
/// the Clock instance. Equivalent to Clock() - *this.
@ -215,6 +222,12 @@ inline void swap(Clock& s1, Clock& s2)
}
inline Clock::ClockVal Clock::raw() const
{
return _clock;
}
} // namespace Poco

View File

@ -109,6 +109,8 @@ public:
TimeVal raw() const;
/// Returns the raw time value.
///
/// Same as epochMicroseconds().
static Timestamp fromEpochTime(std::time_t t);
/// Creates a timestamp from a std::time_t.
@ -246,6 +248,7 @@ inline void swap(Timestamp& s1, Timestamp& s2)
s1.swap(s2);
}
inline Timestamp::TimeVal Timestamp::raw() const
{
return _ts;