std::experimental::future (3) - Linux Manuals
std::experimental::future: std::experimental::future
NAME
std::experimental::future - std::experimental::future
Synopsis
Defined in header <experimental/future>
template< class T > class future; (1) (concurrency TS)
template< class T > class future<T&>; (2) (concurrency TS)
template<> class future<void>; (3) (concurrency TS)
The class template std::experimental::future extends std::future with the following operations:
* an unwrapping constructor from future<future<T>>;
* a member function is_ready to query whether the associated shared state is ready; and
* a member function then to attach a continuation to the future.
However, there is no interoperation between std::experimental::future and std::future.
Member functions
constructor (public member function)
is_ready (public member function)
then (public member function)
operator= (public member function)
Members identical to std::future
Member functions
Note that share() returns a std::experimental::shared_future<T>. The behavior is otherwise identical.
destructor (public member function of std::future<T>)
share (public member function of std::future<T>)
Getting the result
get (public member function of std::future<T>)
State
valid (public member function of std::future<T>)
wait (public member function of std::future<T>)
wait_for (public member function of std::future<T>)
wait_until (public member function of std::future<T>)
Example
This section is incomplete
Reason: no example
See also
shared_future A version of std::shared_future enhanced with continuations and other features
(concurrency TS)