8#ifndef MALENA_DEFERREDOPERATIONSMANAGER_H
9#define MALENA_DEFERREDOPERATIONSMANAGER_H
65 template<
typename Derived>
140#include "../../../src/Core/DeferredOperationsManager.tpp"
CRTP base that gives a manager safe deferred-operation support.
static void processPending()
Flush all pending operations immediately.
static std::vector< std::function< void()> > pendingOperations
Queue of operations pending until the current iteration completes.
static int busyDepth
Iteration nesting depth. Operations are deferred while this is > 0.
static bool isBusy()
Return true if the manager is currently iterating.
static void endBusy()
Signal that iteration has ended; flush pending operations.
static void deferOrExecute(std::function< void()> operation)
Execute operation now if safe, otherwise queue it.
static void beginBusy()
Signal that iteration has begun.
static void clearPending()
Discard all pending operations without executing them.