public class FXSubjectInfo extends AbstractSubjectInfo
A domain object representing a subscription to streaming FX rates for a currency pair, such as USDJPY.
You do not need to construct instances of this class yourself. They are generated from incoming requests by the
FXSubjectParser
and passed to your implementation of CachedDataProvider.onRequest(SubjectInfo)
}.
Constructor and Description |
---|
FXSubjectInfo(String subject,
String baseCurrency,
String termCurrency,
String dealtCurrency,
String tenor,
String amount,
String marginBand)
Creates an instance of FXSubjectInfo with the default subject prefix "FX" and
the provided parameters.
|
FXSubjectInfo(String subject,
String subjectPrefix,
String baseCurrency,
String termCurrency,
String dealtCurrency,
String tenor,
String amount,
String marginBand)
Creates an instance of FXSubjectInfo with a specified subject prefix and the provided parameters.
|
Modifier and Type | Method and Description |
---|---|
String |
getDealtCurrency()
A proxy method that calls the underlying method
AbstractSubjectInfo.getAmountIn() . |
boolean |
isBaseDealt()
Returns a value indicating whether the dealt currency is the base currency or the term currency.
|
boolean |
isMetal()
Returns false.
|
equals, getAmount, getAmountIn, getBaseCurrency, getBrokenDate, getCurrencyPair, getMarginBand, getSubject, getSubjectPrefix, getTenor, getTermCurrency, hashCode, toString
public FXSubjectInfo(String subject, String baseCurrency, String termCurrency, String dealtCurrency, String tenor, String amount, String marginBand)
subject
- The full subject.baseCurrency
- The first currency in the pair. For example, for USDJPY the base currency is USD.termCurrency
- The second currency in the pair. For example, for USDJPY the term currency is JPY.dealtCurrency
- The currency that the amount is specified in. This can be either the base or term currency.tenor
- The tenor for the subscription.amount
- The amount, specified in a quantity of the dealt currency.marginBand
- The margin band or price tier for the subscription.public FXSubjectInfo(String subject, String subjectPrefix, String baseCurrency, String termCurrency, String dealtCurrency, String tenor, String amount, String marginBand)
Creates an instance of FXSubjectInfo with a specified subject prefix and the provided parameters.
Calling this constructor is not recommended unless you are aware of all the client-side and configuration modifications required to support changing the expected format for subscription requests.
subject
- The full subject.subjectPrefix
- The subject prefix. This will be used instead of the default prefix "FX".baseCurrency
- The first currency in the pair. For example, for USDJPY the base currency is USD.termCurrency
- The second currency in the pair. For example, for USDJPY the term currency is JPY.dealtCurrency
- The currency that the amount is specified in. This can be either the base or term currency.tenor
- The tenor for the subscription.amount
- The amount, specified in a quantity of the dealt currency.marginBand
- The margin band or price tier for the subscription.public boolean isMetal()
isMetal
in class AbstractSubjectInfo
public boolean isBaseDealt()
Returns a value indicating whether the dealt currency is the base currency or the term currency. For example:
public String getDealtCurrency()
AbstractSubjectInfo.getAmountIn()
.Copyright © 2015 Caplin Systems.