|
CeresEngine 0.2.0
A game development framework
|
An executor object that dispatches calls to the CoreFoundation CFRunLoop. More...
#include <CeresEngine/Platform/Apple/AppleRunLoop.hpp>
Public Member Functions | |
| Executor (const Executor &)=default | |
| Executor & | operator= (const Executor &)=default |
| Executor (Executor &&)=default | |
| Executor & | operator= (Executor &&)=default |
| AppleRunLoop & | context () const noexcept |
| Obtain the underlying execution context. | |
| void | on_work_started () const noexcept |
| Inform the executor that it has some outstanding work to do. | |
| void | on_work_finished () const noexcept |
| Inform the executor that some work is no longer outstanding. | |
Private Member Functions | |
| Executor (AppleRunLoop *const executionContext, ExecutorBlocking blockingProperty=ExecutorBlocking::never) | |
| Creates a new Executor instance. | |
| AppleRunLoop & | query (ExecutorExecutionContext) const noexcept |
Query the current value of the context property. | |
| ExecutorBlocking | query (ExecutorBlocking) const noexcept |
Query the current value of the blocking property. | |
| std::size_t | query (ExecutorOccupancy) const noexcept |
| Query the occupancy (recommended number of work items) for the system context. | |
| template<typename OtherAllocator > | |
| std::allocator< void > | query (ExecutorAllocator< OtherAllocator >) const noexcept |
Query the current value of the allocator property. | |
| std::allocator< void > | query (ExecutorAllocator< void >) const noexcept |
Query the current value of the allocator property. | |
| Executor | require (ExecutorBlocking blocking) const |
Obtain an executor with the given blocking property. | |
| template<typename Function > | |
| void | execute (ASIO_MOVE_ARG(Function) f) const |
| Execution function. | |
Static Private Member Functions | |
| static constexpr ExecutorMapping | query (ExecutorMapping) noexcept |
Query the current value of the mapping property. | |
| static constexpr ExecutorRelationship | query (ExecutorRelationship) noexcept |
Query the current value of the relationship property. | |
| static constexpr ExecutorOutstandingWork | query (ExecutorOutstandingWork) noexcept |
Query the current value of the outstanding_work property. | |
| static constexpr ExecutorBulkGuarantee | query (ExecutorBulkGuarantee) noexcept |
Query the current value of the bulk_guarantee property. | |
Private Attributes | |
| AppleRunLoop * | mExecutionContext |
| The execution context that the executor will use. | |
| ExecutorBlocking | mBlockingProperty = ExecutorBlocking::never |
| A property that customizes the blocking behavior of the executor. | |
An executor object that dispatches calls to the CoreFoundation CFRunLoop.
|
inlineexplicitprivate |
Creates a new Executor instance.
| executionContext | The owning execution context. |
| blockingProperty | A property that customizes the blocking behavior of the executor. |
|
default |
|
inlinenoexcept |
Obtain the underlying execution context.
|
inlineprivate |
Execution function.
|
inlinenoexcept |
Inform the executor that some work is no longer outstanding.
|
inlinenoexcept |
Inform the executor that it has some outstanding work to do.
|
inlineprivatenoexcept |
Query the current value of the allocator property.
|
inlineprivatenoexcept |
Query the current value of the allocator property.
|
inlineprivatenoexcept |
Query the current value of the blocking property.
|
inlinestaticconstexprprivatenoexcept |
Query the current value of the bulk_guarantee property.
|
inlineprivatenoexcept |
Query the current value of the context property.
|
inlinestaticconstexprprivatenoexcept |
Query the current value of the mapping property.
|
inlineprivatenoexcept |
Query the occupancy (recommended number of work items) for the system context.
|
inlinestaticconstexprprivatenoexcept |
Query the current value of the outstanding_work property.
|
inlinestaticconstexprprivatenoexcept |
Query the current value of the relationship property.
|
inlineprivate |
Obtain an executor with the given blocking property.
Do not call this function directly. It is intended for use with the require customisation point.
For example:
|
friend |
Compare two executors for inequality.
|
private |
A property that customizes the blocking behavior of the executor.
|
private |
The execution context that the executor will use.