Honeycomb
0.1
Component-Model Framework
|
Mixin for common future methods. More...
#include <Future.h>
Public Member Functions | |
template<class Sched , class Func > | |
Future< typename std::result_of< Func(Subclass)>::type > | then (Sched &&sched, Func &&f) |
Append a continuation function that will be called when this future is ready. The ready future is passed in (no wait on future.get()). More... | |
template<class Func > | |
Future< typename std::result_of< Func(Subclass)>::type > | then (Func &&f) |
template<class R2 = typename future::priv::wrappedResult<R>::type, typename std::enable_if< mt::True< R2 >::value &&std::is_base_of< FutureBase, R >::value, int >::type = 0> | |
Future< R2 > | unwrap () |
For wrapped futures Future<Future<R>>, returns a proxy Future<R> that will be ready when the inner future is ready. More... | |
template<class Sched , class Func > | |
auto | then (Sched &&sched, Func &&f) -> Future< typename std::result_of< Func(Subclass)>::type > |
template<class Func > | |
auto | then (Func &&f) -> Future< typename std::result_of< Func(Subclass)>::type > |
Mixin for common future methods.
Future<typename std::result_of<Func(Subclass)>::type> honey::FutureCommon< Subclass, R >::then | ( | Sched && | sched, |
Func && | f | ||
) |
Append a continuation function that will be called when this future is ready. The ready future is passed in (no wait on future.get()).
Future<typename std::result_of<Func(Subclass)>::type> honey::FutureCommon< Subclass, R >::then | ( | Func && | f | ) |
auto honey::FutureCommon< Subclass, R >::then | ( | Sched && | sched, |
Func && | f | ||
) | -> Future<typename std::result_of<Func(Subclass)>::type> |
auto honey::FutureCommon< Subclass, R >::then | ( | Func && | f | ) | -> Future<typename std::result_of<Func(Subclass)>::type> |
|
inline |
For wrapped futures Future<Future<R>>, returns a proxy Future<R> that will be ready when the inner future is ready.
If the wrapped future is shared (ie. Future<SharedFuture<R>>), the result will be copied, otherwise the result will be moved. If the outer or inner future throws an exception, the proxy future will throw it on get().