mirror of
https://github.com/MonsterDruide1/OdysseyDecomp
synced 2026-04-23 09:04:21 +00:00
24 lines
567 B
C++
24 lines
567 B
C++
#include "Library/Execute/ExecutorListFunctor.h"
|
|
|
|
#include "Library/Thread/FunctorV0M.h"
|
|
|
|
namespace al {
|
|
ExecutorListFunctor::ExecutorListFunctor(const char* name, s32 size) : ExecutorListBase(name) {
|
|
mList.allocBuffer(size, nullptr);
|
|
}
|
|
|
|
bool ExecutorListFunctor::isActive() const {
|
|
return !mList.isEmpty();
|
|
}
|
|
|
|
void ExecutorListFunctor::executeList() const {
|
|
for (s32 i = 0; i < mList.size(); i++)
|
|
(*mList[i])();
|
|
}
|
|
|
|
void ExecutorListFunctor::registerFunctor(const FunctorBase& functor) {
|
|
mList.pushBack(functor.clone());
|
|
}
|
|
|
|
} // namespace al
|