26 #ifndef NDN_UTIL_MONOTONIC_DEADLINE_TIMER_HPP
27 #define NDN_UTIL_MONOTONIC_DEADLINE_TIMER_HPP
31 #include <boost/asio/basic_deadline_timer.hpp>
37 struct time_traits<
ndn::time::steady_clock>
49 add(
const time_type& time,
const duration_type& duration)
51 return time + duration;
55 subtract(
const time_type& timeLhs,
const time_type& timeRhs)
57 return timeLhs - timeRhs;
61 less_than(
const time_type& timeLhs,
const time_type& timeRhs)
63 return timeLhs < timeRhs;
66 static boost::posix_time::time_duration
69 return ndn::time::steady_clock::to_posix_duration(duration);
82 #endif // NDN_UTIL_MONOTONIC_DEADLINE_TIMER_HPP
Copyright (c) 2013-2016 Regents of the University of California.
Copyright (c) 2013-2016 Regents of the University of California.
static boost::posix_time::time_duration to_posix_duration(const duration_type &duration)
static time_point now() noexcept
ndn::time::steady_clock::TimePoint time_type
static time_type add(const time_type &time, const duration_type &duration)
ndn::time::steady_clock::Duration duration_type
static duration_type subtract(const time_type &timeLhs, const time_type &timeRhs)
boost::asio::basic_deadline_timer< time::steady_clock > monotonic_deadline_timer
static bool less_than(const time_type &timeLhs, const time_type &timeRhs)