MCPcopy Create free account
hub / github.com/boostorg/asio / wait_duration_msec

Method wait_duration_msec

include/boost/asio/detail/timer_queue.hpp:125–134  ·  view source on GitHub ↗

Get the time for the timer that is earliest in the queue.

Source from the content-addressed store, hash-verified

123
124 // Get the time for the timer that is earliest in the queue.
125 virtual long wait_duration_msec(long max_duration) const
126 {
127 if (heap_.empty())
128 return max_duration;
129
130 return this->to_msec(
131 TimeTraits::to_posix_duration(
132 TimeTraits::subtract(heap_[0].time_, TimeTraits::now())),
133 max_duration);
134 }
135
136 // Get the time for the timer that is earliest in the queue.
137 virtual long wait_duration_usec(long max_duration) const

Callers

nothing calls this directly

Calls 5

to_msecMethod · 0.95
to_posix_durationFunction · 0.85
subtractFunction · 0.85
nowFunction · 0.50
emptyMethod · 0.45

Tested by

no test coverage detected