summaryrefslogtreecommitdiff
path: root/src/mongo/db/logical_time.h
diff options
context:
space:
mode:
authorMisha Tyulenev <misha@mongodb.com>2017-02-03 18:50:54 -0500
committerMisha Tyulenev <misha@mongodb.com>2017-02-03 18:51:34 -0500
commit91bb1bca8e8b4f66a610409ec0ebe10245a02e5a (patch)
tree40ec5c3c3bbe68c7bfcb11ae9eb027922f285cc3 /src/mongo/db/logical_time.h
parent58292592979ff9277ec34390469a1541315104c0 (diff)
downloadmongo-91bb1bca8e8b4f66a610409ec0ebe10245a02e5a.tar.gz
SERVER-27745: Implement LogicalClock
Diffstat (limited to 'src/mongo/db/logical_time.h')
-rw-r--r--src/mongo/db/logical_time.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mongo/db/logical_time.h b/src/mongo/db/logical_time.h
index 6d3fb74a99b..2bc43bf54d4 100644
--- a/src/mongo/db/logical_time.h
+++ b/src/mongo/db/logical_time.h
@@ -38,6 +38,7 @@ namespace mongo {
*/
class LogicalTime {
public:
+ LogicalTime() = default;
explicit LogicalTime(Timestamp);
Timestamp asTimestamp() const {
@@ -57,6 +58,11 @@ public:
std::string toString() const;
+ /**
+ * An uninitialized value of LogicalTime. Default constructed.
+ */
+ static const LogicalTime kUninitialized;
+
private:
uint64_t _time{0};
};