MCPcopy Create free account
hub / github.com/ElementsProject/elements / now

Method now

src/util/time.cpp:79–88  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

77}
78
79NodeClock::time_point NodeClock::now() noexcept
80{
81 const std::chrono::seconds mocktime{nMockTime.load(std::memory_order_relaxed)};
82 const auto ret{
83 mocktime.count() ?
84 mocktime :
85 std::chrono::system_clock::now().time_since_epoch()};
86 assert(ret > 0s);
87 return time_point{ret};
88};
89
90template <typename T>
91T GetTime()

Callers 2

mainFunction · 0.80
mainFunction · 0.80

Calls 2

countMethod · 0.80
loadMethod · 0.45

Tested by 2

mainFunction · 0.64
mainFunction · 0.64