Chatterino
Benchmark.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #include <QElapsedTimer>
4 #include <QString>
5 #include <boost/noncopyable.hpp>
6 
7 namespace chatterino {
8 
9 class BenchmarkGuard : boost::noncopyable
10 {
11 public:
12  BenchmarkGuard(const QString &_name);
14  qreal getElapsedMs();
15 
16 private:
17  QElapsedTimer timer_;
18  QString name_;
19 };
20 
21 } // namespace chatterino
Definition: Application.cpp:48
qreal getElapsedMs()
Definition: Benchmark.cpp:18
Definition: Benchmark.hpp:9
~BenchmarkGuard()
Definition: Benchmark.cpp:12
BenchmarkGuard(const QString &_name)
Definition: Benchmark.cpp:6