mirror of
https://github.com/CraftyBoss/SuperMarioOdysseyOnline.git
synced 2024-11-22 19:25:16 +00:00
26 lines
419 B
C
26 lines
419 B
C
|
#pragma once
|
||
|
|
||
|
#include "prim/seadDelegate.h"
|
||
|
#include "prim/seadNamable.h"
|
||
|
|
||
|
namespace sead
|
||
|
{
|
||
|
class Job : public INamable
|
||
|
{
|
||
|
public:
|
||
|
virtual ~Job();
|
||
|
virtual void invoke() = 0;
|
||
|
};
|
||
|
|
||
|
template <typename T>
|
||
|
class Job0 : public Job
|
||
|
{
|
||
|
public:
|
||
|
Job0(const Delegate<T>& delegate) : mDelegate(delegate) {}
|
||
|
void invoke() override { mDelegate.invoke(); }
|
||
|
|
||
|
protected:
|
||
|
Delegate<T> mDelegate;
|
||
|
};
|
||
|
} // namespace sead
|