mql5/Experts/Motivated/Systems/AbstractSystem.mqh
younglubah-gmail 9639b8b362
2026-06-23 21:44:37 +02:00

38 lines
1.3 KiB
MQL5

//+------------------------------------------------------------------+
//| AbstractSystem.mqh |
//| Copyright 2025, MetaQuotes Ltd. |
//| https://www.mql5.com |
//+------------------------------------------------------------------+
#property copyright "Copyright 2025, MetaQuotes Ltd."
#property link "https://www.mql5.com"
#property version "1.00"
#include "../Utils/CommonHelper.mqh"
#include "../Systems/EventBus.mqh"
//+------------------------------------------------------------------+
//| |
//+------------------------------------------------------------------+
class AbstractSystem
{
protected:
CommonHelper com;
EventBus eventBus;
StructureLevels* levels;
public:
AbstractSystem() {}
~AbstractSystem() {}
virtual void OnCalculate(int i, CommonHelper &commonHelper)
{
com = commonHelper;
}
virtual int OnInit(StructureLevels* levels_, EventBus &_eventBus)
{
levels = levels_;
eventBus = _eventBus;
return INIT_SUCCEEDED;
}
};
//+------------------------------------------------------------------+