summaryrefslogtreecommitdiff
path: root/include/erebos/time.h
diff options
context:
space:
mode:
authorRoman Smrž <roman.smrz@seznam.cz>2020-03-18 22:53:40 +0100
committerRoman Smrž <roman.smrz@seznam.cz>2020-03-23 21:37:30 +0100
commit627d135bf5108f514161e1d37acf6b97c4b3c4a3 (patch)
tree601b2560bb484aedbe51f25a6da3beeae62a78fc /include/erebos/time.h
parent29ade9784fe65ecd686b5e8e18d84e6acc30b37a (diff)
Move UUID and time definitions to separate modules
Diffstat (limited to 'include/erebos/time.h')
-rw-r--r--include/erebos/time.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/include/erebos/time.h b/include/erebos/time.h
new file mode 100644
index 0000000..d8ff5b1
--- /dev/null
+++ b/include/erebos/time.h
@@ -0,0 +1,20 @@
+#pragma once
+
+#include <chrono>
+#include <string>
+
+namespace erebos {
+
+struct ZonedTime
+{
+ explicit ZonedTime(std::string);
+ ZonedTime(std::chrono::system_clock::time_point t): time(t), zone(0) {}
+ explicit operator std::string() const;
+
+ static ZonedTime now();
+
+ std::chrono::system_clock::time_point time;
+ std::chrono::minutes zone; // zone offset
+};
+
+}