7#ifndef STOPWATCH_IMPL_H
8#define STOPWATCH_IMPL_H
10#include <boost/date_time/posix_time/posix_time.hpp>
11#include <boost/scoped_ptr.hpp>
84 logFormat(
const boost::posix_time::time_duration& duration);
107 boost::posix_time::ptime last_start_;
110 boost::posix_time::ptime last_stop_;
114 boost::posix_time::time_duration cumulative_time_;
Stopwatch class implementation.
void start()
Starts the stopwatch.
virtual ~StopwatchImpl()
Virtual destructor.
boost::posix_time::time_duration getTotalDuration() const
Retrieves the total measured duration.
static std::string logFormat(const boost::posix_time::time_duration &duration)
Returns the duration in the textual format which can be directly used in log messages.
StopwatchImpl()
Constructor.
void reset()
Reset the stopwatch.
virtual boost::posix_time::ptime getCurrentTime() const
Returns the current time.
void stop()
Stop the stopwatch.
boost::posix_time::time_duration getLastDuration() const
Retrieves the measured duration.
Defines the logger used by the top-level component of kea-lfc.