libadblockplus
 All Classes Namespaces Functions Variables Typedefs Enumerations Pages
Classes | Public Member Functions | List of all members
AdblockPlus::AsyncExecutor Class Reference

Spawns a new thread for each task and waits for finishing of all spawned threads in the destructor. More...

#include <AsyncExecutor.h>

Public Member Functions

 ~AsyncExecutor ()
 Destructor, it waits for finishing of all already dispatched tasks.
 
void Dispatch (const std::function< void()> &call)
 Creates a new thread in which the call will be executed. More...
 

Detailed Description

Spawns a new thread for each task and waits for finishing of all spawned threads in the destructor.

Member Function Documentation

void AdblockPlus::AsyncExecutor::Dispatch ( const std::function< void()> &  call)

Creates a new thread in which the call will be executed.

Parameters
callis a function object which is called within a worker thread, different from the caller thread. There is no effect if call is empty.

The documentation for this class was generated from the following file: