COrdersCounter – MetaTrader용 라이브러리 4

0
(0)

COrdersCounter - MetaTrader용 라이브러리 4

알렉세이 로파틴 | 영어

견해:
395
평가:

투표: 9

\MQL4\Include\

Descripition:

The class COrdersCounter was developed for counting of the orders with different filters: by symbol of currency, 매직넘버, either closed, either opened orders.

Below is description of the public methods of this class.

Constructors:

방법 설명
COrdersCounter(void) Constructor by default.
COrdersCounter(int magic, string symbol, int counter_mode = MODE_TRADES) 매개변수:마법 - integer value of Magic Number for for the filtering of the orders. When magic = 0 is not used.

symbol - symbol of the instrument. When symbol = "" is not used.

counter_mode - the pool of the orders (either closed, either opened orders). Allows 2 values: MODE_TRADES (기본적으로) - opened orders, MODE_HISTORY - closed orders.

Methods:

방법 설명
void refreshData(void) The method renews data for orders. This method must called before the calling getOrdersCount(), getTotalProfit(), getMarketVolume(), getTotalVolume().
int getOrdersCount(int type) The method returns orders count of defined type. 매개변수:
유형 - type of the orders. Allowed values:
OP_BUY - market buy orders,
OP_SELL - market sell orders,
OP_SELLLIMIT - sell limit orders,
OP_BUYLIMIT - buy limit orders,
OP_SELLSTOP - sell stops orders,
OP_BUYSTOP - buy stop orders.
When type = -1, the method will return total count of all orders.
int getLastOrder() Returns ticket number of last closed/opened order from the retrieved list.
int getFirstOrder() Returns ticket number of first closed/opened order from the retrieved list.
ProfitData getTotalProfit() Returns an instance of the struct ProfitData, containing total profit/loss of the retrieved list.The struct ProfitData contains fields:

double currency - profit/loss in currency
double points - profit/loss in points

double getMarketVolume() Returns the total volume of the market trades of the retrieved list.
double getTotalVolume() Returns the total volume for all orders of of the retrieved list.
void setMagicNumber(int magic) Sets Magic Number 값. 매개변수: 마법 - new value for Magic Number.
void setSymbol(string symbol) Sets Symbol value. 매개변수: symbol - new symbol value of currency.
void setMode(int mode) Set pool. 매개변수: 방법 - the pool type: MODE_TRADES - opened orders, MODE_HISTORY - closed orders.
int getMagicNumber() Returns value of magic (매직넘버) for the filtering of the orders.
string getSymbol() Returns value of symbol.
int getMode() Return type of current pool for orders filtering: MODE_TRADES - opened orders, MODE_HISTORY - closed orders.

이 게시물이 얼마나 유용했나요??

평가하려면 별표를 클릭하세요.!

평균 평점 0 / 5. 투표수: 0

현재까지 투표가 없습니다! 이 게시물을 가장 먼저 평가해 보세요..

이 게시물이 귀하에게 도움이 되지 못했다니 죄송합니다!

이 게시물을 개선해 보겠습니다.!

이 게시물을 개선할 수 있는 방법을 알려주세요.?



작가: 외환 위키 팀
우리는 경험이 풍부한 Forex 트레이더 팀입니다. [2000-2023] 우리 자신의 조건에 따라 삶을 살기 위해 헌신하는 사람들. 우리의 주요 목표는 재정적 독립과 자유를 얻는 것입니다., 우리는 자기 교육을 추구하고 Forex 시장에서 자립 가능한 라이프 스타일을 달성하기 위한 수단으로 광범위한 경험을 얻었습니다..