std::future

From Cppreference

Jump to: navigation, search
Defined in header <future>

template< class T > class future;
(1) (C++11 feature)
template< class T > class future<T&>;
(2) (C++11 feature)
template<>          class future<void>;
(3) (C++11 feature)

[edit] Member functions

(constructor)
constructs the future object
(public member function)
(destructor)
destructs the future object
(public member function)
operator=
moves the future object
(public member function)
share
returns a shared_future referring to the result associated to *this
(public member function)
Getting the result
get
returns the result
(public member function)
State
valid
checks if the result is available
(public member function)
wait
waits for the result to become available
(public member function)
wait_for
waits for the result, returns if it is not
available for the specified timeout duration
(public member function)
wait_until
waits for the result, returns if it is not
available until specified time point has been reached
(public member function)