24#if defined (ONIXS_ILINK3_CXX11)
31class FutureSharedState;
91#if defined (ONIXS_ILINK3_CXX11)
119#if defined (ONIXS_ILINK3_CXX11)
147 const
System::FutureSharedState * state_;
201 FutureBase::operator=(other);
205#if defined (ONIXS_ILINK3_CXX11)
211 FutureBase::operator=(std::move(other));
223 return *
reinterpret_cast<const T *
>(
getValuePtr());
228 FutureBase::swap(other);
234 : FutureBase(state) {}
238 : FutureBase(state, t) {}
240 friend class Implementation::FutureHelper;
#define ONIXS_ILINK3_NULLPTR
#define ONIXS_ILINK3_EXPORTED
#define ONIXS_ILINK3_NOTHROW
Base implementation of SharedFuture<T>.
void swap(FutureBase &other) noexcept
friend class FutureHelper
FutureBase & operator=(const FutureBase &other) noexcept
const void * getValuePtr() const
FutureBase(FutureBase &&other) noexcept
bool has_exception() const
Returns true if the asynchronous result associated with this Future has a stored exception,...
FutureStatus::Enum wait(int timeoutInMs) const
Waits for the result to become available during the timeout.
FutureBase(const FutureBase &other) noexcept
FutureBase(const System::FutureSharedState *state) noexcept
Initializes the instance with shared state.
bool has_value() const
Returns true if the asynchronous result associated with this Future has a stored value,...
bool valid() const noexcept
Check if a future instance is associated with an asynchronous result.
~FutureBase() noexcept
Destroys a future object.
FutureBase(const System::FutureSharedState *state, moving_init_t) noexcept
Initializes the instance with shared state.
std::exception_ptr get_exception_ptr() const
Returns the stored exception.
bool is_ready() const
Returns true if the asynchronous result associated with this Future is ready (has a value or exceptio...
FutureBase & operator=(FutureBase &&other) noexcept
Represents a future result of an asynchronous operation - a result that will eventually appear in the...
void swap(SharedFuture< T > &other) noexcept
swaps two SharedFuture objects
SharedFuture(const SharedFuture< T > &other) noexcept
Copy constructor.
SharedFuture(SharedFuture< T > &&other) noexcept
FutureBase & operator=(SharedFuture< T > &&other) noexcept
Implementation::FutureGetReturn< T >::Type get() const
Returns the result.
SharedFuture< T > & operator=(const SharedFuture< T > &other) noexcept
Copy assignment.
State of a SharedFuture object (similar to std::future_status,.
@ timeout
the shared state did not become ready before specified timeout duration has passed.
@ ready
the shared state is ready.
@ deferred
the shared state contains a deferred function, so the result will be computed only when explicitly re...