eckit::ProgressTimer class

Base classes

class Timer

Constructors, destructors, conversion operators

ProgressTimer(const std::string& name, size_t limit, const std::string& unit, size_t progressCounted = 10000, std::ostream& o = Log::info())
ProgressTimer(const std::string& name, size_t limit, const std::string& unit, double progressTimed = 10., std::ostream& o = Log::info())
operator bool() const

Public functions

auto operator++() -> ProgressTimer&
void start()
void stop()
auto elapsed() -> double
auto elapsed_cpu() -> double
auto name() const -> const std::string&
auto running() const -> bool
void report(const std::string& message = "")
void reset(const std::string& message = "")

Function documentation

eckit::ProgressTimer::ProgressTimer(const std::string& name, size_t limit, const std::string& unit, size_t progressCounted = 10000, std::ostream& o = Log::info())

Parameters
name of the timer, used for output
limit counter maximum value
unit counter unit (singular)
progressCounted
o output stream

eckit::ProgressTimer::ProgressTimer(const std::string& name, size_t limit, const std::string& unit, double progressTimed = 10., std::ostream& o = Log::info())

Parameters
name of the timer, used for output
limit counter maximum value
unit counter unit (singular)
progressTimed
o output stream

void eckit::ProgressTimer::start()

void eckit::ProgressTimer::stop()

double eckit::ProgressTimer::elapsed()

double eckit::ProgressTimer::elapsed_cpu()

const std::string& eckit::ProgressTimer::name() const

bool eckit::ProgressTimer::running() const

void eckit::ProgressTimer::report(const std::string& message = "")

void eckit::ProgressTimer::reset(const std::string& message = "")