public class RT_CalculatorFeature extends java.lang.Object implements RT_Feature
String connection = "user-serial:pass@api-stage.df.factset.com"; RT_Consumer consumer = new RT_Consumer(connection); RT_FieldMap map = new RT_FieldMap("./etc/rt_fields.xml"); RT_CalculatorFeature feature = new RT_CalculatorFeature(map); feature.addNetChangeCalculator(); feature.addPctChangeCalculator(); consumer.enable(feature);
RT_Consumer
,
RT_FieldMap
,
RT_Feature
,
RT_Calculator
,
RT_CalculatorFilter
Constructor and Description |
---|
RT_CalculatorFeature(RT_FieldMap map) |
Modifier and Type | Method and Description |
---|---|
boolean |
addCalculator(RT_Calculator calc)
Adds an instance of a Calculator to the feature.
|
boolean |
addMidNetChangeCalculator()
Convenience method to instruct the toolkit to calculate net change of the mid
price, based on MID_1 and MID_CLOSE, placing the result into MID_NET_CHANGE
|
boolean |
addMidPctChangeCalculator()
Convenience method to instruct the toolkit to calculate the percent change of
the mid price, based on MID_1 and MID_CLOSE, placing the result into
MID_PERCENT_CHANGE
|
boolean |
addNetChangeCalculator()
Convenience method to instruct the toolkit to calculate net change, based on
LAST_1 and PREV_CLOSE, placing the result into NET_CHANGE.
|
boolean |
addPctChangeCalculator()
Convenience method to instruct the toolkit to calculate the percent change,
based on LAST_1 and PREV_CLOSE, placing the result into LAST_PCT_CHG
|
boolean |
addUnadjustedNetChangeCalculator()
Convenience method to instruct the toolkit to calculate net change, based on
LAST_1 and PREV_CLOSE_UNADJ, placing the result into NET_CHANGE
NOTE: You cannot use this and addNetChangeCalculator(). |
boolean |
addUnadjustedPctChangeCalculator()
Convenience method to instruct the toolkit to calculate the percent change,
based on LAST_1 and PREV_CLOSE_UNADJ, placing the result into LAST_PCT_CHG
NOTE: You cannot use this and addPctChangeCalculator().
|
RT_Filter |
createFilter(RT_Consumer cons) |
java.lang.String |
featureType() |
public RT_CalculatorFeature(RT_FieldMap map)
public RT_Filter createFilter(RT_Consumer cons)
createFilter
in interface RT_Feature
public java.lang.String featureType()
featureType
in interface RT_Feature
public boolean addCalculator(RT_Calculator calc)
calc
- The calculator to add to the featurepublic boolean addNetChangeCalculator()
public boolean addMidNetChangeCalculator()
public boolean addUnadjustedNetChangeCalculator()
public boolean addPctChangeCalculator()
public boolean addMidPctChangeCalculator()
public boolean addUnadjustedPctChangeCalculator()