|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Position
A Position represents an aggregation of several open market orders
Method Summary | |
---|---|
FXPair |
getPair()
Gets the pair of this position's open market orders. |
double |
getPrice()
Gets the average price of open market orders, weighted by size. |
long |
getUnits()
Gets the number of units in all open market orders |
double |
getUnrealizedPL(FXTick currPrice)
Calculate the current profit of this position, based on the number of units and average price |
java.lang.String |
toString()
Overridden Object.toString method |
Method Detail |
---|
double getPrice()
long getUnits()
FXPair getPair()
double getUnrealizedPL(FXTick currPrice)
currPrice
- An FXTick representing the current rate of this market's pair
java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |