Version: SMASH-3.4
chrono.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2014-2015,2017-2018,2020
3  * SMASH Team
4  *
5  * GNU General Public License (GPLv3 or later)
6  */
7 #ifndef SRC_INCLUDE_SMASH_CHRONO_H_
8 #define SRC_INCLUDE_SMASH_CHRONO_H_
9 
10 #include <chrono>
11 
12 /**
13  * \file
14  *
15  * Collection of useful type aliases to measure and output the (real)
16  * runtime. Not connected to the simulation time.
17  */
18 
19 namespace smash {
20 
21 /// Type (alias) that is used to store the current time.
22 using SystemTimePoint = std::chrono::time_point<std::chrono::system_clock>;
23 
24 /// Type (alias) used to obtain the current time via SystemClock:Now().
25 using SystemClock = std::chrono::system_clock;
26 
27 /// The time duration type (alias) used for measuring run times.
28 using SystemTimeSpan = SystemClock::duration;
29 
30 } // namespace smash
31 
32 #endif // SRC_INCLUDE_SMASH_CHRONO_H_
Definition: action.h:24
SystemClock::duration SystemTimeSpan
The time duration type (alias) used for measuring run times.
Definition: chrono.h:28
std::chrono::system_clock SystemClock
Type (alias) used to obtain the current time via SystemClock:Now().
Definition: chrono.h:25
std::chrono::time_point< std::chrono::system_clock > SystemTimePoint
Type (alias) that is used to store the current time.
Definition: chrono.h:22