Package com.wombat.mamda
Class MamdaAuctionListener
- java.lang.Object
-
- com.wombat.mamda.MamdaAuctionListener
-
- All Implemented Interfaces:
MamdaAuctionRecap
,MamdaAuctionUpdate
,MamdaBasicEvent
,MamdaBasicRecap
,MamdaMsgListener
public class MamdaAuctionListener extends java.lang.Object implements MamdaMsgListener, MamdaBasicEvent, MamdaBasicRecap, MamdaAuctionRecap, MamdaAuctionUpdate
A MamdaAuctionListener is class that specializes in handling Auction order updates. An Auction order occurs when too many orders of a particular type - either buy, sell or limit - for listed securities and not enough of the other, matching orders are received by an exchange. Developers provide their own implementation of the MamdaAuctionHandler interface and will be delivered notifications for Auction updates.
-
-
Field Summary
-
Constructor Summary
Constructors Constructor Description MamdaAuctionListener()
constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addHandler(MamdaAuctionHandler handler)
addHandler - Registers handler interested in receiving update update and recap events.void
clearCache()
clearCache - clears all cached data by resetting to default values.com.wombat.mama.MamaDateTime
getActivityTime()
getActivityTimeshort
getActivityTimeFieldState()
getActivityTimeFieldStatelong
getEventSeqNum()
getEventSeqNumshort
getEventSeqNumFieldState()
getEventSeqNumFieldStatecom.wombat.mama.MamaDateTime
getEventTime()
getEventTimeshort
getEventTimeFieldState()
getEventTimeFieldStatejava.lang.String
getIssueSymbol()
getIssueSymbolshort
getIssueSymbolFieldState()
getIssueSymbolFieldStatecom.wombat.mama.MamaDateTime
getLineTime()
getLineTimeshort
getLineTimeFieldState()
getLineTimeFieldStatejava.lang.String
getPartId()
getPartIdshort
getPartIdFieldState()
getPartIdFieldStatecom.wombat.mama.MamaDateTime
getSendTime()
getSendTimeshort
getSendTimeFieldState()
getSendTimeFieldStatecom.wombat.mama.MamaDateTime
getSrcTime()
getSrcTimeshort
getSrcTimeFieldState()
getSrcTimeFieldStatejava.lang.String
getSymbol()
getSymbolshort
getSymbolFieldState()
getSymbolFieldStatecom.wombat.mama.MamaPrice
getUncrossPrice()
getUncrossPriceshort
getUncrossPriceFieldState()
getUncrossPriceFieldStateshort
getUncrossPriceInd()
getUncrossPriceIndshort
getUncrossPriceIndFieldState()
getUncrossPriceIndFieldStatelong
getUncrossVolume()
getUncrossVolumeshort
getUncrossVolumeFieldState()
getUncrossVolumeFieldStatevoid
onMsg(MamdaSubscription subscription, com.wombat.mama.MamaMsg msg, short msgType)
Implementation of MamdaListener interface.
-
-
-
Field Detail
-
mSrcTime
public com.wombat.mama.MamaDateTime mSrcTime
-
mActTime
public com.wombat.mama.MamaDateTime mActTime
-
mSendTime
public com.wombat.mama.MamaDateTime mSendTime
-
mLineTime
public com.wombat.mama.MamaDateTime mLineTime
-
mEventTime
public com.wombat.mama.MamaDateTime mEventTime
-
mEventSeqNum
public com.wombat.mama.MamaLong mEventSeqNum
-
mIssueSymbol
public com.wombat.mama.MamaString mIssueSymbol
-
mPartId
public com.wombat.mama.MamaString mPartId
-
mSymbol
public com.wombat.mama.MamaString mSymbol
-
mUncrossPrice
public com.wombat.mama.MamaPrice mUncrossPrice
-
mUncrossVolume
public com.wombat.mama.MamaLong mUncrossVolume
-
mUncrossPriceInd
public MamdaUncrossPriceInd mUncrossPriceInd
-
mSrcTimeFieldState
public MamdaFieldState mSrcTimeFieldState
-
mActTimeFieldState
public MamdaFieldState mActTimeFieldState
-
mSendTimeFieldState
public MamdaFieldState mSendTimeFieldState
-
mLineTimeFieldState
public MamdaFieldState mLineTimeFieldState
-
mEventTimeFieldState
public MamdaFieldState mEventTimeFieldState
-
mIssueSymbolFieldState
public MamdaFieldState mIssueSymbolFieldState
-
mPartIdFieldState
public MamdaFieldState mPartIdFieldState
-
mSymbolFieldState
public MamdaFieldState mSymbolFieldState
-
mEventSeqNumFieldState
public MamdaFieldState mEventSeqNumFieldState
-
mUncrossPriceFieldState
public MamdaFieldState mUncrossPriceFieldState
-
mUncrossVolumeFieldState
public MamdaFieldState mUncrossVolumeFieldState
-
mUncrossPriceIndFieldState
public MamdaFieldState mUncrossPriceIndFieldState
-
tmpPrice
public com.wombat.mama.MamaPrice tmpPrice
-
tmpDouble
public com.wombat.mama.MamaDouble tmpDouble
-
-
Method Detail
-
clearCache
public void clearCache()
clearCache - clears all cached data by resetting to default values.- Parameters:
cache
- The Auction order cache to clear.
-
addHandler
public void addHandler(MamdaAuctionHandler handler)
addHandler - Registers handler interested in receiving update update and recap events. Currently only one handler can and must be registered.- Parameters:
handler
- - the handler to be registered.
-
getActivityTime
public com.wombat.mama.MamaDateTime getActivityTime()
getActivityTime- Specified by:
getActivityTime
in interfaceMamdaBasicEvent
- Specified by:
getActivityTime
in interfaceMamdaBasicRecap
- Returns:
- mActTime
- See Also:
MamdaBasicEvent.getActivityTime()
-
getSrcTime
public com.wombat.mama.MamaDateTime getSrcTime()
getSrcTime- Specified by:
getSrcTime
in interfaceMamdaBasicEvent
- Specified by:
getSrcTime
in interfaceMamdaBasicRecap
- Returns:
- mSrcTime
- See Also:
MamdaBasicEvent.getSrcTime()
-
getSendTime
public com.wombat.mama.MamaDateTime getSendTime()
getSendTime- Specified by:
getSendTime
in interfaceMamdaBasicRecap
- Returns:
- mSendTime
- See Also:
MamdaBasicEvent#getSendTime
-
getLineTime
public com.wombat.mama.MamaDateTime getLineTime()
getLineTime- Specified by:
getLineTime
in interfaceMamdaBasicRecap
- Returns:
- mLineTime
- See Also:
MamdaBasicEvent#getLineTime
-
getIssueSymbol
public java.lang.String getIssueSymbol()
getIssueSymbol- Returns:
- mIssueSymbol
-
getPartId
public java.lang.String getPartId()
getPartId- Specified by:
getPartId
in interfaceMamdaBasicRecap
- Returns:
- mPartId
-
getSymbol
public java.lang.String getSymbol()
getSymbol- Specified by:
getSymbol
in interfaceMamdaBasicRecap
- Returns:
- mSymbol
-
getEventTime
public com.wombat.mama.MamaDateTime getEventTime()
getEventTime- Specified by:
getEventTime
in interfaceMamdaBasicEvent
- Returns:
- mEventTime
-
getEventSeqNum
public long getEventSeqNum()
getEventSeqNum- Specified by:
getEventSeqNum
in interfaceMamdaBasicEvent
- Returns:
- mEventSeqNum
-
getUncrossPrice
public com.wombat.mama.MamaPrice getUncrossPrice()
getUncrossPrice- Specified by:
getUncrossPrice
in interfaceMamdaAuctionRecap
- Specified by:
getUncrossPrice
in interfaceMamdaAuctionUpdate
- Returns:
- mUncrossPrice
-
getUncrossVolume
public long getUncrossVolume()
getUncrossVolume- Specified by:
getUncrossVolume
in interfaceMamdaAuctionRecap
- Specified by:
getUncrossVolume
in interfaceMamdaAuctionUpdate
- Returns:
- mUncrossVolume
-
getUncrossPriceInd
public short getUncrossPriceInd()
getUncrossPriceInd- Specified by:
getUncrossPriceInd
in interfaceMamdaAuctionRecap
- Specified by:
getUncrossPriceInd
in interfaceMamdaAuctionUpdate
- Returns:
- mUncrossPriceInd
-
getActivityTimeFieldState
public short getActivityTimeFieldState()
getActivityTimeFieldState- Specified by:
getActivityTimeFieldState
in interfaceMamdaBasicEvent
- Specified by:
getActivityTimeFieldState
in interfaceMamdaBasicRecap
- Returns:
- mActTimeFieldState
- See Also:
MamdaBasicEvent.getActivityTimeFieldState()
-
getSrcTimeFieldState
public short getSrcTimeFieldState()
getSrcTimeFieldState- Specified by:
getSrcTimeFieldState
in interfaceMamdaBasicEvent
- Specified by:
getSrcTimeFieldState
in interfaceMamdaBasicRecap
- Returns:
- mSrcTimeFieldState
- See Also:
MamdaBasicEvent.getSrcTimeFieldState()
-
getSendTimeFieldState
public short getSendTimeFieldState()
getSendTimeFieldState- Specified by:
getSendTimeFieldState
in interfaceMamdaBasicRecap
- Returns:
- mSendTimeFieldState
- See Also:
MamdaBasicEvent#getSendTimeFieldState
-
getLineTimeFieldState
public short getLineTimeFieldState()
getLineTimeFieldState- Specified by:
getLineTimeFieldState
in interfaceMamdaBasicRecap
- Returns:
- mLineTimeFieldState
- See Also:
MamdaBasicEvent#getLineTimeFieldState
-
getIssueSymbolFieldState
public short getIssueSymbolFieldState()
getIssueSymbolFieldState- Returns:
- mIssueSymbolFieldState
-
getPartIdFieldState
public short getPartIdFieldState()
getPartIdFieldState- Specified by:
getPartIdFieldState
in interfaceMamdaBasicRecap
- Returns:
- mPartIdFieldState
-
getSymbolFieldState
public short getSymbolFieldState()
getSymbolFieldState- Specified by:
getSymbolFieldState
in interfaceMamdaBasicRecap
- Returns:
- mSymbolFieldState
-
getEventTimeFieldState
public short getEventTimeFieldState()
getEventTimeFieldState- Specified by:
getEventTimeFieldState
in interfaceMamdaBasicEvent
- Returns:
- mEventTimeFieldState
-
getEventSeqNumFieldState
public short getEventSeqNumFieldState()
getEventSeqNumFieldState- Specified by:
getEventSeqNumFieldState
in interfaceMamdaBasicEvent
- Returns:
- mEventSeqNumFieldState
-
getUncrossPriceFieldState
public short getUncrossPriceFieldState()
getUncrossPriceFieldState- Specified by:
getUncrossPriceFieldState
in interfaceMamdaAuctionRecap
- Specified by:
getUncrossPriceFieldState
in interfaceMamdaAuctionUpdate
- Returns:
- mUncrossPriceFieldState
-
getUncrossVolumeFieldState
public short getUncrossVolumeFieldState()
getUncrossVolumeFieldState- Specified by:
getUncrossVolumeFieldState
in interfaceMamdaAuctionRecap
- Specified by:
getUncrossVolumeFieldState
in interfaceMamdaAuctionUpdate
- Returns:
- mUncrossVolumeFieldState
-
getUncrossPriceIndFieldState
public short getUncrossPriceIndFieldState()
getUncrossPriceIndFieldState- Specified by:
getUncrossPriceIndFieldState
in interfaceMamdaAuctionRecap
- Specified by:
getUncrossPriceIndFieldState
in interfaceMamdaAuctionUpdate
- Returns:
- mUncrossPriceIndFieldState
-
onMsg
public void onMsg(MamdaSubscription subscription, com.wombat.mama.MamaMsg msg, short msgType)
Implementation of MamdaListener interface.- Specified by:
onMsg
in interfaceMamdaMsgListener
- Parameters:
subscription
- The MamdaSubscription to which this listener was registered.msg
- The MamaMsg received by the underlying MAMA API and which resulted in this callback being invoked.msgType
- The message type. e.g. INITIAL, RECAP, UPDATE etc.
-
-