Alsvinn  0.5.3
The fast FVM simulator with UQ support
TimerDatabase.hpp
Go to the documentation of this file.
1 #pragma once
3 #include <boost/property_tree/ptree.hpp>
4 namespace alsutils {
5 namespace timer {
6 
7 class TimerDatabase {
8  TimerDatabase() {}
9 public:
10  static TimerDatabase& getInstance();
11 
12  template<class ...T>
13  TimerData& getTimerData(T... names) {
14  return root.getTimerData(names...);
15  }
16 
17 
18  void print();
19 
20  boost::property_tree::ptree getTimesAsPropertyTree() const;
21 
22 private:
23  TimerData root;
24 };
25 } // namespace timer
26 } // namespace alsutils
Various utilities for mpi and cuda.
Definition: Factory.hpp:3
boost::property_tree::ptree getTimesAsPropertyTree() const
Definition: TimerDatabase.cpp:18
TimerData & getTimerData(const std::string &name, T... names)
Definition: TimerData.hpp:15
TimerData & getTimerData(T... names)
Definition: TimerDatabase.hpp:13
Definition: TimerData.hpp:10
void print()
Definition: TimerDatabase.cpp:12
Definition: TimerDatabase.hpp:7
static TimerDatabase & getInstance()
Definition: TimerDatabase.cpp:7