mql5/Include/MasterOfPuppetsLib/GeneratorsDefinition.mqh
2026-03-05 23:35:38 +03:00

26 lines
1.5 KiB
MQL5

//+------------------------------------------------------------------+
//| GeneratorsDefinition.mqh |
//| Copyright 2026, MasterOfPuppets |
//| https://forge.mql5.io/masterofpuppets/mql5 |
//+------------------------------------------------------------------+
#ifndef MASTER_OF_PUPPETS_LIB_GENERATORS_DEFINITION_MQH
#define MASTER_OF_PUPPETS_LIB_GENERATORS_DEFINITION_MQH
#property copyright "Copyright 2026, MasterOfPuppets"
#property link "https://forge.mql5.io/masterofpuppets/mql5"
#define MASTER_OF_PUPPETS_LIB_ACTION_NAME(inputVariable) DO_##inputVariable
#define MASTER_OF_PUPPETS_LIB_ACTION(inputVariable) Action::MASTER_OF_PUPPETS_LIB_ACTION_NAME(inputVariable)
#define MASTER_OF_PUPPETS_LIB_GENERATE_ACTION(inputVariable, actionKey) \
MASTER_OF_PUPPETS_LIB_ACTION_NAME(inputVariable) = ActionKey::actionKey,
#define MASTER_OF_PUPPETS_LIB_GENERATE_ADD_ACTION(inputVariable, actionKey) \
actions.AddAction(inputVariable, MASTER_OF_PUPPETS_LIB_ACTION(inputVariable), #inputVariable);
#define MASTER_OF_PUPPETS_LIB_GENERATE_CASE(inputVariable, actionKey) \
case MASTER_OF_PUPPETS_LIB_ACTION(inputVariable): \
On##inputVariable(MASTER_OF_PUPPETS_LIB_ACTION(inputVariable)); \
break;
#define MASTER_OF_PUPPETS_LIB_GENERATE_INPUT(inputVariable, actionKey) \
sinput ActionKey inputVariable = ActionKey::actionKey;
#endif
//+------------------------------------------------------------------+