Lagrange
|
Similar to a VerboseTimer, but uses RAII to call tick()/tock(). More...
#include <lagrange/utils/timing.h>
Public Member Functions | |
ScopedTimer (std::string prefix, spdlog::logger *log=nullptr, spdlog::level::level_enum level=spdlog::level::debug) | |
Constructs a new instance. More... | |
ScopedTimer (ScopedTimer &&)=default | |
ScopedTimer & | operator= (ScopedTimer &&)=default |
Similar to a VerboseTimer, but uses RAII to call tick()/tock().
|
inline |
Constructs a new instance.
[in] | prefix | Prefix name to prepend to each log message. Defaults to empty string. |
[in] | log | Optional logger to use. Defaults to the lagrange logger. |
[in] | level | Log level to use. Defaults to debug. |