Sese Framework  2.3.0
A cross-platform framework
Loading...
Searching...
No Matches
sese::GlobalThreadPool Class Reference

Global thread pools, which use system thread pools on Windows, and slacker singleton thread pools on UNIX platforms. More...

#include <GlobalThreadPool.h>

Public Member Functions

template<class ReturnType >
std::shared_future< ReturnType > postTask (const std::function< ReturnType()> &func)
 

Static Public Member Functions

static void postTask (const std::function< void()> &func)
 
template<class RETURN_TYPE >
static std::shared_future< RETURN_TYPE > postTask (const std::function< RETURN_TYPE()> &func)
 

Static Private Attributes

static SingletonPtr< ThreadPoolglobalThreadPool
 

Detailed Description

Global thread pools, which use system thread pools on Windows, and slacker singleton thread pools on UNIX platforms.

Member Function Documentation

◆ postTask() [1/3]

template<class RETURN_TYPE >
static std::shared_future< RETURN_TYPE > sese::GlobalThreadPool::postTask ( const std::function< RETURN_TYPE()> & func)
static

◆ postTask() [2/3]

template<class ReturnType >
std::shared_future< ReturnType > sese::GlobalThreadPool::postTask ( const std::function< ReturnType()> & func)

◆ postTask() [3/3]

void sese::GlobalThreadPool::postTask ( const std::function< void()> & func)
static

References globalThreadPool.

Referenced by sese::asyncWithGlobalPool().

Member Data Documentation

◆ globalThreadPool

SingletonPtr<ThreadPool> sese::GlobalThreadPool::globalThreadPool
staticprivate

Referenced by postTask().


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