22 #ifndef NDN_TIME_CUSTOM_CLOCK_HPP 23 #define NDN_TIME_CUSTOM_CLOCK_HPP 36 template<
typename BaseClock>
43 virtual typename BaseClock::time_point
49 virtual boost::posix_time::time_duration
50 toPosixDuration(
const typename BaseClock::duration& duration)
const = 0;
64 shared_ptr<CustomSystemClock> systemClock =
nullptr);
69 #endif // NDN_TIME_CUSTOM_CLOCK_HPP Copyright (c) 2013-2017 Regents of the University of California.
virtual BaseClock::time_point getNow() const =0
CustomClock< steady_clock > CustomSteadyClock
virtual std::string getSince() const =0
Class implementing custom system or steady clock behavior.
CustomClock< system_clock > CustomSystemClock
virtual boost::posix_time::time_duration toPosixDuration(const typename BaseClock::duration &duration) const =0
void setCustomClocks(shared_ptr< CustomSteadyClock > steadyClock=nullptr, shared_ptr< CustomSystemClock > systemClock=nullptr)
Set custom system and steady clocks.
virtual ~CustomClock()=default