last ...
This commit is contained in:
@@ -4064,6 +4064,7 @@ bool ToPivot(
|
||||
* @param prefix: string, Specified Pattern Type ...
|
||||
* @param peakPriceType: ENUM_X_PRICE, Specified Peak Pivot's Applied Price ...
|
||||
* @param valePriceType: ENUM_X_PRICE, Specified Vale Pivot's Applied Price ...
|
||||
* @param setFromByBreakerBar: bool, Set Box From Time to Breaker Bar ...
|
||||
*
|
||||
* @return ( bool )
|
||||
*/
|
||||
@@ -4073,7 +4074,8 @@ bool ToBox(
|
||||
ENUM_X_DIRECTION forDir,
|
||||
string prefix = NULL,
|
||||
ENUM_X_PRICE peakPriceType = X_PRICE_HIGH,
|
||||
ENUM_X_PRICE valePriceType = X_PRICE_LOW //
|
||||
ENUM_X_PRICE valePriceType = X_PRICE_LOW,
|
||||
bool setFromByBreakerBar = false //
|
||||
)
|
||||
{
|
||||
//
|
||||
@@ -4119,7 +4121,8 @@ bool ToBox(
|
||||
forDir,
|
||||
iPattern,
|
||||
peakPriceType,
|
||||
valePriceType //
|
||||
valePriceType,
|
||||
setFromByBreakerBar //
|
||||
);
|
||||
}
|
||||
//
|
||||
@@ -4177,6 +4180,7 @@ bool ToBox(
|
||||
* @param prefix: string, Specified Pattern Type ...
|
||||
* @param peakPriceType: ENUM_X_PRICE, Specified Peak Pivot's Applied Price ...
|
||||
* @param valePriceType: ENUM_X_PRICE, Specified Vale Pivot's Applied Price ...
|
||||
* @param setFromByBreakerBar: bool, Set Box From Time to Breaker Bar ...
|
||||
*
|
||||
* @return ( bool )
|
||||
*/
|
||||
@@ -4186,7 +4190,8 @@ bool ToBox(
|
||||
ENUM_X_DIRECTION patternDir,
|
||||
ENUM_X_BAR_PATTERN pattern,
|
||||
ENUM_X_PRICE peakPriceType = X_PRICE_HIGH,
|
||||
ENUM_X_PRICE valePriceType = X_PRICE_LOW //
|
||||
ENUM_X_PRICE valePriceType = X_PRICE_LOW,
|
||||
bool setFromByBreakerBar = false //
|
||||
)
|
||||
{
|
||||
//
|
||||
@@ -4245,17 +4250,21 @@ bool ToBox(
|
||||
//
|
||||
case X_BAR_PATTERN_HIGH: {
|
||||
//
|
||||
tmpBar.Clean();
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
peakPriceType,
|
||||
peakPriceType,
|
||||
X_DIRECTION_BULLISH //
|
||||
);
|
||||
if (has)
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
//
|
||||
tmpBar.Clean();
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
peakPriceType,
|
||||
peakPriceType,
|
||||
X_DIRECTION_BULLISH //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
@@ -4267,17 +4276,21 @@ bool ToBox(
|
||||
//
|
||||
case X_BAR_PATTERN_LOW: {
|
||||
//
|
||||
tmpBar.Clean();
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
valePriceType,
|
||||
valePriceType,
|
||||
X_DIRECTION_BEARISH //
|
||||
);
|
||||
if (has)
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
//
|
||||
tmpBar.Clean();
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
valePriceType,
|
||||
valePriceType,
|
||||
X_DIRECTION_BEARISH //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
@@ -4289,20 +4302,24 @@ bool ToBox(
|
||||
//
|
||||
case X_BAR_PATTERN_MOMENTUM: {
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
@@ -4314,20 +4331,24 @@ bool ToBox(
|
||||
//
|
||||
case X_BAR_PATTERN_ENGULFED: {
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
@@ -4362,20 +4383,24 @@ bool ToBox(
|
||||
//
|
||||
case X_BAR_PATTERN_PINNED: {
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
@@ -4407,7 +4432,10 @@ bool ToBox(
|
||||
if (has)
|
||||
{
|
||||
//
|
||||
iFrom = tmpBar.time;
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
|
||||
//
|
||||
int idx = -1;
|
||||
@@ -4421,20 +4449,24 @@ bool ToBox(
|
||||
//
|
||||
case X_BAR_PATTERN_PIERCING: {
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
@@ -4446,20 +4478,24 @@ bool ToBox(
|
||||
//
|
||||
case X_BAR_PATTERN_RISING: {
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
@@ -4471,20 +4507,24 @@ bool ToBox(
|
||||
//
|
||||
case X_BAR_PATTERN_FLAG: {
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
@@ -4498,20 +4538,24 @@ bool ToBox(
|
||||
//
|
||||
case X_BAR_PATTERN_SIGNALKEY: {
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
@@ -4566,20 +4610,24 @@ bool ToBox(
|
||||
//
|
||||
case X_BAR_PATTERN_SUPPORT: {
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
@@ -4597,20 +4645,24 @@ bool ToBox(
|
||||
//
|
||||
case X_BAR_PATTERN_RESISTANCE: {
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
if (setFromByBreakerBar)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
//
|
||||
tmpBar.Clean();
|
||||
ENUM_X_PRICE iPType = isBullish
|
||||
? valePriceType
|
||||
: peakPriceType;
|
||||
has = GetBreakerBar(
|
||||
bar,
|
||||
tmpBar,
|
||||
iPType,
|
||||
iPType,
|
||||
patternDir //
|
||||
);
|
||||
if (has)
|
||||
{
|
||||
iFrom = tmpBar.time;
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user