Package org.drip.product.params
Class CurrencyPair
java.lang.Object
org.drip.product.params.CurrencyPair
public class CurrencyPair
extends java.lang.Object
CurrencyPair class contains the numerator currency, the denominator currency, the quote currency,
and the PIP Factor. It exports serialization into and de-serialization out of byte arrays.
- Module = Product Core Module
- Library = Fixed Income Analytics
- Project = Product Components/Baskets for Credit, FRA, FX, Govvie, Rates, and Option AssetClasses
- Package = Fixed Income Product Customization Parameters
- Author:
- Lakshmi Krishnamurthy
-
Constructor Summary
Constructors Constructor Description CurrencyPair(java.lang.String strNumCcy, java.lang.String strDenomCcy, java.lang.String strQuoteCcy, double dblPIPFactor)
Construct the currency pair from the numerator currency, the denominator currency, the quote currency, and the PIP Factor -
Method Summary
Modifier and Type Method Description java.lang.String
code()
Get the currency pair codejava.lang.String
denomCcy()
Get the denominator currencystatic CurrencyPair
FromCode(java.lang.String strCode)
Construct the Currency Pair from the Codejava.lang.String
inverseCode()
Get the inverse currency pair codejava.lang.String
numCcy()
Get the numerator currencydouble
pipFactor()
Get the PIP Factorjava.lang.String
quoteCcy()
Get the quote currencyjava.lang.String
toString()
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Constructor Details
-
CurrencyPair
public CurrencyPair(java.lang.String strNumCcy, java.lang.String strDenomCcy, java.lang.String strQuoteCcy, double dblPIPFactor) throws java.lang.ExceptionConstruct the currency pair from the numerator currency, the denominator currency, the quote currency, and the PIP Factor- Parameters:
strNumCcy
- Numerator currencystrDenomCcy
- Denominator currencystrQuoteCcy
- Quote CurrencydblPIPFactor
- PIP Factor- Throws:
java.lang.Exception
- Thrown if the inputs are invalid
-
-
Method Details
-
FromCode
Construct the Currency Pair from the Code- Parameters:
strCode
- Currency Pair Code- Returns:
- The Currency Pair
-
numCcy
public java.lang.String numCcy()Get the numerator currency- Returns:
- Numerator currency
-
denomCcy
public java.lang.String denomCcy()Get the denominator currency- Returns:
- Denominator currency
-
quoteCcy
public java.lang.String quoteCcy()Get the quote currency- Returns:
- Quote currency
-
code
public java.lang.String code()Get the currency pair code- Returns:
- Currency pair code
-
inverseCode
public java.lang.String inverseCode()Get the inverse currency pair code- Returns:
- The Inverse Currency pair code
-
pipFactor
public double pipFactor()Get the PIP Factor- Returns:
- PIP Factor
-
toString
public java.lang.String toString()- Overrides:
toString
in classjava.lang.Object
-