Time-based coroutine suspension helpers.
More...
#include <chrono>
#include <userver/engine/deadline.hpp>
Go to the source code of this file.
|
namespace | engine |
| Asynchronous engine primitives.
|
|
|
void | engine::Yield () |
| Suspends execution for a brief period of time, possibly allowing other tasks to execute.
|
|
template<typename Rep , typename Period > |
void | engine::InterruptibleSleepFor (const std::chrono::duration< Rep, Period > &duration) |
|
template<typename Clock , typename Duration > |
void | engine::InterruptibleSleepUntil (const std::chrono::time_point< Clock, Duration > &time_point) |
|
template<typename Rep , typename Period > |
void | engine::SleepFor (const std::chrono::duration< Rep, Period > &duration) |
| Suspends execution for at least a specified amount of time.
|
|
template<typename Clock , typename Duration > |
void | engine::SleepUntil (const std::chrono::time_point< Clock, Duration > &time_point) |
| Suspends execution until the specified time point is reached.
|
|
Time-based coroutine suspension helpers.
Definition in file sleep.hpp.