Package deltix.qsrv.hf.pub
Class OptionFilter
- java.lang.Object
-
- deltix.qsrv.hf.pub.InstrumentFilter
-
- deltix.qsrv.hf.pub.OptionFilter
-
- All Implemented Interfaces:
java.io.Serializable
public class OptionFilter extends InstrumentFilter
Extends InstrumentFilter with option-specific properties.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static int
OPTIONS_ROOT_LENGTH
static int
OPTIONS_SYMBOL_LENGTH
static boolean
USE_NEW_SYMBOLOGY
-
Fields inherited from class deltix.qsrv.hf.pub.InstrumentFilter
type
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
acceptMessage(deltix.qsrv.hf.pub.InstrumentMessage msg)
boolean
acceptOptionRoot(java.lang.CharSequence symbol)
Filter based on the first 3 or 6 characters of the symbolboolean
acceptOptionSymbol(byte[] bytes, int offset, int length)
Filter an option message based on symbol (ticker).boolean
acceptOptionSymbol(java.lang.CharSequence symbol)
Filter an option message based on the 5-character symbol (21 character in new symbology)boolean
acceptSymbol(java.lang.CharSequence symbol)
protected void
addSymbol(java.lang.CharSequence symbol, int start, int end)
Adds the specified option root to subscription.void
addSymbol(java.lang.String symbol)
Adds the specified option root to subscription.static boolean
assertValid(java.lang.CharSequence name)
static java.lang.CharSequence
getRootSymbol(java.lang.CharSequence symbol)
protected void
removeSymbol(java.lang.CharSequence symbol, int start, int end)
Removes the specified option root from message subscription.void
removeSymbol(java.lang.String symbol)
Removes a symbol from message subscription.void
subscribe(java.lang.CharSequence option)
void
unsubscribe(java.lang.CharSequence option)
-
Methods inherited from class deltix.qsrv.hf.pub.InstrumentFilter
acceptAllSymbols, acceptMessage, acceptMessageType, acceptMessageType, acceptMessageType, acceptSymbol, acceptSymbol, addMessageType, addMessageTypes, addSymbol, addSymbols, addSymbols, applyMessageTypeMask, clear, clearMessageTypes, clearSymbols, dump, dump, getMessageTypeMask, getMessageTypes, getSymbols, getType, isRestricted, isUnrestricted, read, removeMessageType, removeMessageTypes, removeSymbol, removeSymbols, removeSymbols, setAllMessageTypes, setAllSymbols, setCopy, setMessageTypes, setRestricted, setSymbols, setUnion, setUnrestricted, toString, write
-
-
-
-
Method Detail
-
getRootSymbol
public static java.lang.CharSequence getRootSymbol(java.lang.CharSequence symbol)
-
addSymbol
public void addSymbol(java.lang.String symbol)
Adds the specified option root to subscription.- Overrides:
addSymbol
in classInstrumentFilter
- Parameters:
symbol
- The option root to add.
-
subscribe
public void subscribe(java.lang.CharSequence option)
-
unsubscribe
public void unsubscribe(java.lang.CharSequence option)
-
addSymbol
protected void addSymbol(java.lang.CharSequence symbol, int start, int end)
Adds the specified option root to subscription.- Overrides:
addSymbol
in classInstrumentFilter
- Parameters:
symbol
- The symbol to add.end
- index of final position (excludive)
-
removeSymbol
public void removeSymbol(java.lang.String symbol)
Description copied from class:InstrumentFilter
Removes a symbol from message subscription.- Overrides:
removeSymbol
in classInstrumentFilter
- Parameters:
symbol
- The symbol to remove.
-
removeSymbol
protected void removeSymbol(java.lang.CharSequence symbol, int start, int end)
Removes the specified option root from message subscription.- Overrides:
removeSymbol
in classInstrumentFilter
- Parameters:
symbol
- The symbol to remove.end
- index of final position (excludive)
-
acceptSymbol
public boolean acceptSymbol(java.lang.CharSequence symbol)
- Overrides:
acceptSymbol
in classInstrumentFilter
-
acceptOptionSymbol
public boolean acceptOptionSymbol(java.lang.CharSequence symbol)
Filter an option message based on the 5-character symbol (21 character in new symbology)
-
acceptOptionSymbol
public boolean acceptOptionSymbol(byte[] bytes, int offset, int length)
Filter an option message based on symbol (ticker).
-
acceptOptionRoot
public boolean acceptOptionRoot(java.lang.CharSequence symbol)
Filter based on the first 3 or 6 characters of the symbol
-
acceptMessage
public boolean acceptMessage(deltix.qsrv.hf.pub.InstrumentMessage msg)
- Overrides:
acceptMessage
in classInstrumentFilter
-
assertValid
public static boolean assertValid(java.lang.CharSequence name) throws InvalidInstrumentException
- Throws:
InvalidInstrumentException
-
-