8#include <userver/engine/deadline.hpp>
10USERVER_NAMESPACE_BEGIN
20void InterruptibleSleepUntil(Deadline);
21void SleepUntil(Deadline);
27template <
typename Rep,
typename Period>
29 InterruptibleSleepUntil(Deadline::FromDuration(duration));
35template <
typename Clock,
typename Duration>
37 const std::chrono::time_point<Clock, Duration>& time_point) {
38 InterruptibleSleepUntil(Deadline::FromTimePoint(time_point));
42template <
typename Rep,
typename Period>
43void SleepFor(
const std::chrono::duration<Rep, Period>& duration) {
44 SleepUntil(Deadline::FromDuration(duration));
48template <
typename Clock,
typename Duration>
49void SleepUntil(
const std::chrono::time_point<Clock, Duration>& time_point) {
50 SleepUntil(Deadline::FromTimePoint(time_point));