|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.otfeed.event.OTTrade
public final class OTTrade
Provides either real-time or historical trade information. This event indicates that shares were sold and purchased (excepting some tracing messages). OTTrade stores price, size and other information about the deal.
Constructor Summary | |
---|---|
OTTrade()
Default constructor. |
|
OTTrade(java.util.Date timestamp,
int size,
double price,
long volume,
int sequenceNumber,
char indicator,
char tickIndicator,
java.util.Set<TradePropertyEnum> properties,
java.lang.String exchange,
java.lang.String symbol)
Constructor. |
Method Summary | |
---|---|
int |
compareTo(OTTrade other)
|
boolean |
equals(java.lang.Object o)
|
java.lang.String |
getExchange()
|
char |
getIndicator()
|
double |
getPrice()
|
int |
getSequenceNumber()
|
int |
getSize()
|
java.lang.String |
getSymbol()
|
char |
getTickIndicator()
|
java.util.Date |
getTimestamp()
|
java.util.Set<TradePropertyEnum> |
getTradeProperties()
Returns set of boolean properties of this trade. |
long |
getVolume()
|
int |
hashCode()
|
boolean |
isCancel()
|
boolean |
isClose()
|
boolean |
isFromBook()
|
boolean |
isHigh()
|
boolean |
isLow()
|
boolean |
isOpen()
|
boolean |
isUpdateLast()
|
boolean |
isUpdateVolume()
|
void |
setExchange(java.lang.String exchange)
Sets exchange code. |
void |
setIndicator(char indicator)
Sets indicator. |
void |
setPrice(double price)
Sets trade price. |
void |
setSequenceNumber(int sequenceNumber)
Sets sequence number of trade. |
void |
setSize(int size)
Sets number of shares traded in this transaction. |
void |
setSymbol(java.lang.String symbol)
Sets symbol code. |
void |
setTickIndicator(char tickIndicator)
Sets tick indicator: D - Down, U - Up, N - Not provided. |
void |
setTimestamp(java.util.Date timestamp)
Sets time of the event. |
void |
setTradeProperties(java.util.Set<TradePropertyEnum> p)
|
void |
setVolume(long volume)
Sets accumulated volume for the trading day. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public OTTrade()
public OTTrade(java.util.Date timestamp, int size, double price, long volume, int sequenceNumber, char indicator, char tickIndicator, java.util.Set<TradePropertyEnum> properties, java.lang.String exchange, java.lang.String symbol)
timestamp
- Time when the event occurred.size
- Number of shares traded in this transaction.price
- Trade price.volume
- Accumulated volume for the trading day.sequenceNumber
- Sequence number of trade.indicator
- Indicator.tickIndicator
- Tick indicator: D - Down, U - Up, N - Not provided.properties
- Trade properties.exchange
- Exchange code.symbol
- Symbol code.Method Detail |
---|
public java.util.Date getTimestamp()
public void setTimestamp(java.util.Date timestamp)
timestamp
- Time when the event occurred.public int getSize()
public void setSize(int size)
size
- Number of shares traded in this transaction.public double getPrice()
public void setPrice(double price)
price
- Trade price.public long getVolume()
public void setVolume(long volume)
volume
- Accumulated volume for the trading day.public int getSequenceNumber()
public void setSequenceNumber(int sequenceNumber)
sequenceNumber
- Sequence number of trade.public char getIndicator()
public void setIndicator(char indicator)
indicator
- Indicator.public char getTickIndicator()
public void setTickIndicator(char tickIndicator)
tickIndicator
- Sets tick indicator: D - Down, U - Up, N - Not provided.public boolean isOpen()
public boolean isHigh()
public java.util.Set<TradePropertyEnum> getTradeProperties()
isXXX
methods of this calsss.
public void setTradeProperties(java.util.Set<TradePropertyEnum> p)
public boolean isLow()
public boolean isClose()
public boolean isUpdateLast()
public boolean isUpdateVolume()
public boolean isCancel()
public boolean isFromBook()
public java.lang.String getExchange()
public void setExchange(java.lang.String exchange)
exchange
- Exchange code.public java.lang.String getSymbol()
public void setSymbol(java.lang.String symbol)
symbol
- Symbol code.public java.lang.String toString()
toString
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int compareTo(OTTrade other)
compareTo
in interface java.lang.Comparable<OTTrade>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |