last ...
This commit is contained in:
@@ -406,6 +406,13 @@ class XCX121SMCXWZSignalDetector : public XCBase
|
||||
analyseState,
|
||||
consolidationState //
|
||||
);
|
||||
if (hasWaitingZones)
|
||||
{
|
||||
//
|
||||
// Validate Waiting Zones ...
|
||||
workingZone.ValidateWaitingZones(zIndex);
|
||||
hasWaitingZones = HasChild(workingZone.waitingZones);
|
||||
}
|
||||
|
||||
//
|
||||
// Checking Working Zone Destory or not ...
|
||||
|
||||
@@ -605,6 +605,83 @@ struct X121SMCStrategyXWZWorkingZone
|
||||
return result;
|
||||
}
|
||||
|
||||
//
|
||||
int ValidateWaitingZones(
|
||||
int barIndex = 0 //
|
||||
)
|
||||
{
|
||||
//
|
||||
int result = 0;
|
||||
|
||||
//
|
||||
bool has = false;
|
||||
|
||||
//
|
||||
if (barIndex < 0)
|
||||
{
|
||||
barIndex = 0;
|
||||
}
|
||||
|
||||
//
|
||||
has = IsValid() &&
|
||||
HasWaitingZones();
|
||||
if (!has)
|
||||
{
|
||||
return result;
|
||||
}
|
||||
|
||||
//
|
||||
int removeIDX[];
|
||||
result = CountWaitingZones();
|
||||
for (int i = 0; i < result; i++)
|
||||
{
|
||||
//
|
||||
XOBFVG iOBFVG = waitingZones[i];
|
||||
|
||||
//
|
||||
XOHCL iInvalidBar;
|
||||
has = iOBFVG.IsValidZone(
|
||||
iInvalidBar,
|
||||
barIndex //
|
||||
);
|
||||
if (!has)
|
||||
{
|
||||
//
|
||||
Add(
|
||||
i,
|
||||
removeIDX //
|
||||
);
|
||||
|
||||
//
|
||||
AddRef(
|
||||
iOBFVG,
|
||||
unavailableZones //
|
||||
);
|
||||
}
|
||||
|
||||
//
|
||||
iInvalidBar.Clean();
|
||||
}
|
||||
|
||||
//
|
||||
has = HasChild(removeIDX);
|
||||
if (has)
|
||||
{
|
||||
//
|
||||
CleanupArray(
|
||||
removeIDX,
|
||||
waitingZones //
|
||||
);
|
||||
}
|
||||
Clean(removeIDX);
|
||||
|
||||
//
|
||||
result = CountWaitingZones();
|
||||
|
||||
//
|
||||
return result;
|
||||
}
|
||||
|
||||
//
|
||||
bool IsZoneRejected(
|
||||
XOBFVG &zone,
|
||||
|
||||
Reference in New Issue
Block a user