Go to the documentation of this file.
44 #ifndef CGU_ASYNC_RESULT_H
45 #define CGU_ASYNC_RESULT_H
269 res = std::move(val);
319 while (!done) cond.
wait(mutex);
369 while (!done) cond.
wait(mutex);
371 return std::move(res);
Definition: application.h:44
int broadcast()
Definition: mutex.h:483
T get() const
Definition: async_result.h:317
A wrapper class for pthread condition variables.
Definition: mutex.h:449
bool set_error(int err=-1)
Definition: async_result.h:396
A thread-safe asynchronous result class.
Definition: async_result.h:165
int wait(Mutex &mutex)
Definition: mutex.h:508
bool set(T &&val)
Definition: async_result.h:266
AsyncResult()
Definition: async_result.h:190
AsyncResult & operator=(const AsyncResult &)=delete
bool set(const T &val)
Definition: async_result.h:235
int get_error() const
Definition: async_result.h:415
~AsyncResult()
Definition: async_result.h:192
A scoped locking class for exception safe Mutex locking.
Definition: mutex.h:207
#define CGU_GLIB_MEMORY_SLICES_FUNCS
Definition: cgu_config.h:84
A class enabling the cancellation state of a thread to be controlled.
Definition: thread.h:686
Provides wrapper classes for pthread mutexes and condition variables, and scoped locking classes for ...
bool is_done() const
Definition: async_result.h:428
A wrapper class for pthread mutexes.
Definition: mutex.h:117
T move_get()
Definition: async_result.h:367