class ClosedPosition
Parents
object
Brief
The class provides access to information about a closed position
| Public Methods | |
|---|---|
| getTradeID | Gets the unique identification number of the position |
| getAccountId | Gets the unique identification number of the account the position was closed on |
| getAccountName | Gets the unique name of the account the position was closed on |
| getAccountKind | Gets the type of the account the position was closed on |
| getOfferId | Gets the unique identification number of the instrument traded |
| getAmount | Gets the amount of the closed position |
| getBuySell | Gets the trade operation the position was opened by |
| getOpenRate | Gets the price at which the position was opened |
| getOpenTime | Gets the date and time when the position was opened |
| getOpenQuoteId | Gets the unique identifier of the pair of prices bid and ask at which the position was opened |
| getOpenOrderId | Gets the unique identification number of the order the position was opened by |
| getOpenOrderReqId | Gets the identifier of the order request the position was opened by |
| getOpenOrderRequestTXT | Gets the custom identifier of the order the position was opened by |
| getCloseRate | Get the price at which the position was closed |
| getCloseTime | Gets the date and time when the position was closed |
| getCloseQuoteId | Get the unique identifier of the price pair bid and ask at which the position was closed |
| getCloseOrderId | Gets the unique identifier of the order at which the position was closed |
| getCloseOrderReqId | Gets the unique identifier of the order request at which the position was closed |
| getCloseOrderRequestTXT | Gets the custom identifier of the order at which the position was closed |
| getCloseOrderParties | Gets the unique identifier of the environment that was used to close the position |
| getCommission | Gets the amount of funds subtracted from the account balance to pay for the brokers service in accordance with the terms and conditions of the account trading agreement |
| getRolloverInterest | Gets the cumulative amount of funds that is added the account balance for holding the position overnight |
| getTradeIdOrigin | Gets the unique identification number of the position a partial closing of which resulted in opening of the current position |
| getTradeIdRemain | Gets the unique identification number of the position opened as a result of the partial closing of the current position |
| getValueDate | Gets the simulated delivery date |
| getDividends | Gets the amount of dividends earned or paid for the position |
| getPL | Gets the profit or loss of one lot of the position in the account currency |
| getPLPips | Gets the profit or loss of one lot of the position in pips |
| getNetPL | Gets the amount of the position profit/loss including commissions, interest, and dividends |
| getGrossPL | Gets the profit or loss of the position in the account currency |
| ClosedPosition | This method is a constructor for the class representing a closed position, it initializes the various properties describing closed position with default values. The constructor does not return any values |