aboutsummaryrefslogtreecommitdiffstats
path: root/src/base/timestamp.hpp
diff options
context:
space:
mode:
authorAlexander Sulfrian <alexander@sulfrian.net>2015-04-03 20:27:27 +0200
committerAlexander Sulfrian <alexander@sulfrian.net>2015-04-03 20:27:27 +0200
commitfe9648fa1cdc8f9cf5216a88fadb8b96604047fd (patch)
tree011b7956b38a08b771d349866f9fabc0d5689fc9 /src/base/timestamp.hpp
parent0d9371a00c47991e9f62053b649d39e9504680d8 (diff)
downloadusdx-fe9648fa1cdc8f9cf5216a88fadb8b96604047fd.tar.gz
usdx-fe9648fa1cdc8f9cf5216a88fadb8b96604047fd.tar.xz
usdx-fe9648fa1cdc8f9cf5216a88fadb8b96604047fd.zip
base/time: Replaces by std::chrono.
Diffstat (limited to 'src/base/timestamp.hpp')
-rw-r--r--src/base/timestamp.hpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/base/timestamp.hpp b/src/base/timestamp.hpp
index e6fc5247..095d5fa2 100644
--- a/src/base/timestamp.hpp
+++ b/src/base/timestamp.hpp
@@ -25,6 +25,8 @@
#ifndef TIMESTAMP_HPP
#define TIMESTAMP_HPP
+#include <chrono>
+
namespace usdx
{
/**
@@ -37,7 +39,7 @@ namespace usdx
/**
* internal storage of the point of time represented by the timestamp instance
*/
- float time;
+ std::chrono::steady_clock::time_point time;
public:
/**
@@ -52,7 +54,7 @@ namespace usdx
* @return true, if the elapsed time is less than the given duration,
* otherwise false
*/
- bool since(float duration) const;
+ bool since(std::chrono::milliseconds duration) const;
/**
* Update the stored point of time to the current time.