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