Ating for MQL5
Loading...
Searching...
No Matches
InstitutionalArithmeticPrices Class Reference

Class to handle arithmetic price calculations and validations for institutional trading. More...

Classes

struct  Prices
 Structure to store computed prices and line type. More...
 
struct  Setting
 Structure to store arithmetic sequence settings. More...
 

Public Types

enum  ENUM_CHECK {
  CHECK_ARG_LINE_GENERATOR_PASSED , ERR_NO_ENOUGH_STEP , ERR_START_OVER_END , ERR_ADD_OVER_STEP ,
  ERR_PRICE_OUT_LINES
}
 Enum for handling different types of errors and checks in line generation. More...
 
enum  ENUM_TYPE_NEAR_LINES { TYPE_BETWEEN_PARALLELS , TYPE_INSIDE_PARALLEL , ERR_INVALID_LINES }
 Enum for handling different types of near lines. More...
 

Public Member Functions

 InstitutionalArithmeticPrices (void)
 Default constructor for the InstitutionalArithmeticPrices class.
 
void UpdateSetting (double startAdd, double step, double add)
 Updates the settings for arithmetic sequence.
 
Setting GetSetting ()
 Retrieves the current settings.
 
void GetSetting (Setting &param)
 Retrieves the current settings by reference.
 
ENUM_CHECK CheckArg ()
 Checks the arguments for line generation.
 
string EnumCheckLinesGeneratorToString (ENUM_CHECK enum_result)
 Converts the ENUM_CHECK result to a string.
 
Prices Generate (double closePrice)
 Generates price levels based on the given close price.
 
string CommentToShow ()
 Returns a formatted comment with line information.
 

Detailed Description

Class to handle arithmetic price calculations and validations for institutional trading.

Member Enumeration Documentation

◆ ENUM_CHECK

Enum for handling different types of errors and checks in line generation.

Enumerator
CHECK_ARG_LINE_GENERATOR_PASSED 

Check passed.

ERR_NO_ENOUGH_STEP 

Error: Not enough steps.

ERR_START_OVER_END 

Error: Start is greater than end.

ERR_ADD_OVER_STEP 

Error: Addition is greater than step.

ERR_PRICE_OUT_LINES 

Error: Price is out of lines.

◆ ENUM_TYPE_NEAR_LINES

Enum for handling different types of near lines.

Enumerator
TYPE_BETWEEN_PARALLELS 

Type: Between parallels.

TYPE_INSIDE_PARALLEL 

Type: Inside parallel.

ERR_INVALID_LINES 

Error: Invalid lines.

Constructor & Destructor Documentation

◆ InstitutionalArithmeticPrices()

InstitutionalArithmeticPrices::InstitutionalArithmeticPrices ( void )
inline

Default constructor for the InstitutionalArithmeticPrices class.

Member Function Documentation

◆ CheckArg()

InstitutionalArithmeticPrices::ENUM_CHECK InstitutionalArithmeticPrices::CheckArg ( )

Checks the arguments for line generation.

Returns
The result of the check as ENUM_CHECK

◆ CommentToShow()

string InstitutionalArithmeticPrices::CommentToShow ( )

Returns a formatted comment with line information.

Returns
A string with the line details

◆ EnumCheckLinesGeneratorToString()

string InstitutionalArithmeticPrices::EnumCheckLinesGeneratorToString ( ENUM_CHECK enum_result)

Converts the ENUM_CHECK result to a string.

Parameters
enum_resultThe ENUM_CHECK result to convert
Returns
A string representation of the enum result

◆ Generate()

InstitutionalArithmeticPrices::Prices InstitutionalArithmeticPrices::Generate ( double closePrice)

Generates price levels based on the given close price.

Parameters
closePriceThe close price to use for generation
Returns
The computed Prices structure

◆ GetSetting() [1/2]

InstitutionalArithmeticPrices::Setting InstitutionalArithmeticPrices::GetSetting ( )

Retrieves the current settings.

Returns
The current settings

◆ GetSetting() [2/2]

void InstitutionalArithmeticPrices::GetSetting ( Setting & param)

Retrieves the current settings by reference.

Parameters
paramReference to a Setting structure to store the settings

◆ UpdateSetting()

void InstitutionalArithmeticPrices::UpdateSetting ( double startAdd,
double step,
double add )

Updates the settings for arithmetic sequence.

Parameters
startAddStart value for addition
stepStep size for arithmetic sequence
addAdditional value for adjustment

The documentation for this class was generated from the following file: