SimPHash/EA.mq5
2026-06-28 16:04:15 -05:00

55 lines
2.2 KiB
MQL5

//+------------------------------------------------------------------+
//| EA.mq5 |
//| Copyright 2026, Niquel Mendoza. |
//| https://www.mql5.com/ |
//+------------------------------------------------------------------+
#property copyright "Copyright 2026, Niquel Mendoza."
#property link "https://www.mql5.com/"
#property version "1.00"
#property strict
//+------------------------------------------------------------------+
//| Include |
//+------------------------------------------------------------------+
#include "Src\\PerfectHash.mqh"
//+------------------------------------------------------------------+
//| Inputs |
//+------------------------------------------------------------------+
input string InpYamlFileName = "C:\\Users\\USER\\AppData\\Roaming\\MetaQuotes\\Terminal\\D0E8209F77C8CF37AD8BF550E51FF075\\MQL5\\Shared Projects\\MQLArticles\\Utils\\EnumsStr\\config.yaml"; // Yaml file ubication
input ENUM_VERBOSE_LOG_LEVEL InpLogLevel = VERBOSE_LOG_LEVEL_ALL; // Log level
//+------------------------------------------------------------------+
//| Expert initialization function |
//+------------------------------------------------------------------+
int OnInit()
{
//---
TSN::CPerfectHashGenerator ph;
ph.AddLogFlags(InpLogLevel);
//---
if(!ph.Init(InpYamlFileName))
return INIT_PARAMETERS_INCORRECT;
if(!ph.RunAlg())
return INIT_FAILED;
//---
return(2); // exito
}
//+------------------------------------------------------------------+
//| Expert deinitialization function |
//+------------------------------------------------------------------+
void OnDeinit(const int reason)
{
//---
}
//+------------------------------------------------------------------+
//| Expert tick function |
//+------------------------------------------------------------------+
void OnTick()
{
//---
}
//+------------------------------------------------------------------+