24 #include <condition_variable> 46 template<
class Fn,
class ... Args>
47 bool Submit(Fn&& fn, Args&& ... args)
49 return SubmitToThread(
AWS_BUILD_TYPED_FUNCTION(std::bind(std::forward<Fn>(fn), std::forward<Args>(args)...),
void()));
57 virtual bool SubmitToThread(std::function<
void()>&&) = 0;
69 bool SubmitToThread(std::function<
void()>&&)
override;
97 bool SubmitToThread(std::function<
void()>&&)
override;
101 std::mutex m_queueLock;
102 std::mutex m_syncPointLock;
103 std::condition_variable m_syncPoint;
111 std::function<void()>* PopTask();
std::vector< T, Aws::Allocator< T > > Vector
bool Submit(Fn &&fn, Args &&...args)
std::queue< T, Deque< T > > Queue
#define AWS_BUILD_TYPED_FUNCTION(func, type)
JSON (JavaScript Object Notation).