last works ...

This commit is contained in:
2025-10-28 17:31:10 +03:30
parent 7960b76510
commit e6e449bdb6
3 changed files with 1054 additions and 415 deletions
@@ -4002,7 +4002,7 @@ class XCXFIMAHelperParser : XCBase
{
//
// Define Requirements ...
//
datetime toTime = NULL;
datetime fromTime = NULL;
@@ -5121,7 +5121,7 @@ class XCXFIMAHelperParser : XCBase
{
//
// Define Requirements ...
//
datetime toTime = NULL;
datetime fromTime = NULL;
@@ -6240,7 +6240,7 @@ class XCXFIMAHelperParser : XCBase
{
//
// Define Requirements ...
//
datetime toTime = NULL;
datetime fromTime = NULL;
@@ -7359,7 +7359,7 @@ class XCXFIMAHelperParser : XCBase
{
//
// Define Requirements ...
//
datetime toTime = NULL;
datetime fromTime = NULL;
@@ -7467,6 +7467,158 @@ class XCXFIMAHelperParser : XCBase
return result;
}
/**
* Retrieve Cycles MA(s) ...
*
* @param scMA: double, reference to holds cycle value ...
* @param mcMA: double, reference to holds cycle value ...
* @param lcMA: double, reference to holds cycle value ...
* @param hcMA: double, reference to holds cycle value ...
* @param barIndex: int, Specified Bar Index ...
*/
void GetCycleMAs(
double &scMA,
double &mcMA,
double &lcMA,
double &hcMA,
int barIndex = 0 //
)
{
//
// Prepare ...
scMA = EMPTY_VALUE;
mcMA = EMPTY_VALUE;
lcMA = EMPTY_VALUE;
hcMA = EMPTY_VALUE;
//
// Normalize ...
barIndex = NormalizeBarIndex(barIndex);
//
// Validate ...
bool has = IsValid();
if (!has)
{
return;
}
//
scMA = helper.GetSCMA(barIndex);
mcMA = helper.GetMCMA(barIndex);
lcMA = helper.GetLCMA(barIndex);
hcMA = helper.GetHCMA(barIndex);
}
/**
* Retrieve Cycles MA State(s) ...
*
* @param scMAState: double, reference to holds cycle value ...
* @param mcMAState: double, reference to holds cycle value ...
* @param lcMAState: double, reference to holds cycle value ...
* @param hcMAState: double, reference to holds cycle value ...
* @param barIndex: int, Specified Bar Index ...
*/
void GetCycleMAStates(
double &scMAState,
double &mcMAState,
double &lcMAState,
double &hcMAState,
int barIndex = 0 //
)
{
//
// Prepare ...
scMAState = EMPTY_VALUE;
mcMAState = EMPTY_VALUE;
lcMAState = EMPTY_VALUE;
hcMAState = EMPTY_VALUE;
//
// Normalize ...
barIndex = NormalizeBarIndex(barIndex);
//
// Validate ...
bool has = IsValid();
if (!has)
{
return;
}
//
scMAState = helper.GetSCMAState(barIndex);
mcMAState = helper.GetMCMAState(barIndex);
lcMAState = helper.GetLCMAState(barIndex);
hcMAState = helper.GetHCMAState(barIndex);
}
/**
* Check Cycle Hind and Long is Bullish or not ...
*
* @param barIndex: int, Specified Bar Index ...
*
* @return ( bool )
*/
bool IsCycleMABullish(int barIndex = 0)
{
//
bool result = false;
//
// Normalize ...
barIndex = NormalizeBarIndex(barIndex);
//
// Validate ...
result = IsValid();
if (!result)
{
return result;
}
//
result =
IsLCMABullish(barIndex) &&
IsHCMABullish(barIndex);
//
return result;
}
/**
* Check Cycle Hind and Long is Bearish or not ...
*
* @param barIndex: int, Specified Bar Index ...
*
* @return ( bool )
*/
bool IsCycleMABearish(int barIndex = 0)
{
//
bool result = false;
//
// Normalize ...
barIndex = NormalizeBarIndex(barIndex);
//
// Validate ...
result = IsValid();
if (!result)
{
return result;
}
//
result =
IsLCMABearish(barIndex) &&
IsHCMABearish(barIndex);
//
return result;
}
//
// Boundary Tools ...
// =============================