future::wait_until 方法
阻止当前线程,直到异步关联的就绪状态或将指定时间点之后。
template<class Clock, class Duration>
future_status wait_until(
const chrono::time_point<Clock, Duration>& Abs_time) const;
参数
- Abs_time
指定的时间后,线程的对象可以取消。chrono::time_point
返回值
一个 future_status,指示返回的原因。
备注
只有当其异步提供程序存储了返回值或存储了异常时,关联的异步状态才会是 ready。
要求
标头: future
命名空间: std