框架上传
This commit is contained in:
30
Assets/00.StaryEvo/Runtime/Design/ISystem.cs
Normal file
30
Assets/00.StaryEvo/Runtime/Design/ISystem.cs
Normal file
@@ -0,0 +1,30 @@
|
||||
namespace Stary.Evo
|
||||
{
|
||||
public interface ISystem: IBelongToArchitecture,ICanSetArchitecture,ICanGetData,ICanGetUtility ,ICanRegisterEvent,ICanSendEvent,ICanGetSystem
|
||||
{
|
||||
void Init();
|
||||
void Dispose();
|
||||
}
|
||||
public abstract class AbstractSystem : ISystem
|
||||
{
|
||||
private IArchitecture mArchitecture;
|
||||
IArchitecture IBelongToArchitecture.GetArchitecture()
|
||||
{
|
||||
return mArchitecture;
|
||||
}
|
||||
|
||||
void ICanSetArchitecture.SetArchitecture(IArchitecture architecture)
|
||||
{
|
||||
mArchitecture = architecture;
|
||||
}
|
||||
|
||||
void ISystem.Init()
|
||||
{
|
||||
OnInit();
|
||||
}
|
||||
|
||||
public abstract void Dispose();
|
||||
|
||||
protected abstract void OnInit();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user