|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.shimari.fxtp.FXTP_Order
A Bean representing an Order on FXTP--something that would reside in a book, and we typically call a set of orders a Book.
Constructor Summary | |
FXTP_Order(java.lang.Integer userId,
java.lang.String symbol,
int quantity,
int price,
boolean isABid)
|
Method Summary | |
int |
compareTo(java.lang.Object o)
Sort by symbol, bid/ask, price, quantity, and user id. |
boolean |
equals(java.lang.Object o)
|
int |
getContractPrice()
This is the actual price for the underlying contracts. |
double |
getCost()
|
java.lang.Integer |
getId()
The id of the user who submitted the order. |
int |
getPrice()
This price is the "positive" price used in quoting bid/ask ranges for yes contracts. |
int |
getQuantity()
This value is always positive, and represents the number of contracts ordered. |
int |
getSignedQuantity()
Return the quantity as a positive number for bids, and negative number for asks. |
java.lang.String |
getSymbol()
|
int |
hashCode()
|
boolean |
isBid()
True if this is an order to purchase yes contracts; false if it is an order to purchase no contracts. |
java.lang.String |
toShortString()
Return a string representing the order omitting the user and the symbol. |
java.lang.String |
toString()
Returns a string representing the order, including the symbol. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public FXTP_Order(java.lang.Integer userId, java.lang.String symbol, int quantity, int price, boolean isABid)
Method Detail |
public java.lang.String toString()
public boolean equals(java.lang.Object o)
public int hashCode()
public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
public java.lang.String toShortString()
public boolean isBid()
public java.lang.String getSymbol()
public java.lang.Integer getId()
public int getPrice()
public int getContractPrice()
public int getQuantity()
public int getSignedQuantity()
public double getCost()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |