Interface for running tasks asynchronously.
More...
#include <IAsyncContext.h>
|
virtual int8_t | threads () const noexcept=0 |
| Returns size of underlying thread pool. More...
|
|
virtual bool | valid () const noexcept=0 |
| Tells validness of internal state. More...
|
|
virtual bool | clearTaskQueue () noexcept=0 |
| Clears tasks not yet taken by any thread. More...
|
|
virtual bool | resize (const int8_t newThreadCount) noexcept=0 |
| Resizes internal thread pool to some new size param newThreadCount New size of thread pool. Should not be less than 1. More...
|
|
virtual bool | stop () noexcept=0 |
| Waits for all already running tasks to complete, then stops every thread. Do not use threadpool afterwards. Is called on destruction. More...
|
|
virtual int32_t | retain () noexcept=0 |
| Increase strong reference count. More...
|
|
virtual int32_t | retainLocked () noexcept=0 |
| Increase strong reference count thread safely. More...
|
|
virtual int32_t | release () noexcept=0 |
| Decrease strong reference count. More...
|
|
virtual int32_t | getRefCount () const noexcept=0 |
| Get actual strong reference count. More...
|
|
virtual int32_t | retainWeak () noexcept=0 |
| Increase weak reference count. More...
|
|
virtual int32_t | releaseWeak () noexcept=0 |
| Decrease weak reference count. More...
|
|
virtual int32_t | getWeakRefCount () const noexcept=0 |
| Get actual weak reference count. More...
|
|
Interface for running tasks asynchronously.
Contains thread pool under hood.
virtual bool fsdk::IAsyncContext::clearTaskQueue |
( |
| ) |
|
|
pure virtualnoexcept |
Clears tasks not yet taken by any thread.
- Returns
- True on success, false otherwise.
virtual bool fsdk::IAsyncContext::resize |
( |
const int8_t |
newThreadCount | ) |
|
|
pure virtualnoexcept |
Resizes internal thread pool to some new size param newThreadCount New size of thread pool. Should not be less than 1.
- Returns
- True on success, false otherwise.
virtual bool fsdk::IAsyncContext::stop |
( |
| ) |
|
|
pure virtualnoexcept |
Waits for all already running tasks to complete, then stops every thread. Do not use threadpool afterwards. Is called on destruction.
- Returns
- True on success, false otherwise.
virtual int8_t fsdk::IAsyncContext::threads |
( |
| ) |
const |
|
pure virtualnoexcept |
Returns size of underlying thread pool.
- Returns
- Count of threads.
virtual bool fsdk::IAsyncContext::valid |
( |
| ) |
const |
|
pure virtualnoexcept |
Tells validness of internal state.
- Returns
- True if valid, false otherwise.
The documentation for this struct was generated from the following file: