public class DerivedFXBasis extends FXBasisCurve
NULL_SER_STRING, VERSION
Constructor and Description |
---|
DerivedFXBasis(byte[] ab)
FXBasis de-serialization from input byte array
|
DerivedFXBasis(CurrencyPair cp,
JulianDate dtSpot,
double dblFXSpot,
double[] adblDate,
double[] adblFXBasis,
boolean bIsFXBasisBootstrapped)
Constructs an FXBasis instance from the currency pair, FX Spot, and FX basis parameters
|
Modifier and Type | Method and Description |
---|---|
boolean |
buildInterpolator()
Build the interpolator post the curve sweeping build
|
boolean |
bumpNodeValue(int iIndex,
double dblValue)
Bump the node value at the node specified the index by the value
|
Curve |
createParallelShiftedCurve(double dblShift)
Create a parallel quote shifted curve
|
Curve |
createTweakedCurve(NodeTweakParams ntp)
Create the curve from the tweaked parameters
|
Serializer |
deserialize(byte[] ab)
De-serialize from a byte array.
|
java.lang.String |
displayString()
Get the display String - mostly for informational purposes
|
CalibratableComponent[] |
getCalibComponents()
Retrieve all the calibration components
|
java.lang.String[] |
getCompMeasures()
Retrieve all the calibration measures
|
double[] |
getCompQuotes()
Retrieve all the calibration quotes
|
CurrencyPair |
getCurrencyPair()
Returns the currency pair instance
|
double[] |
getFullFXFwd(ValuationParams valParam,
DiscountCurve dcNum,
DiscountCurve dcDenom,
boolean bBasisOnDenom,
boolean bFwdAsPIP)
Returns the array of full FX Forwards
|
double |
getFXSpot()
Gets the FX Spot
|
java.lang.String |
getName()
Gets the curve name
|
JulianDate |
getNodeDate(int iIndex)
Get the date at the node specified by the index
|
double |
getQuote(java.lang.String strInstr)
Retrieve the calibration quote of the given instrument
|
JulianDate |
getSpotDate()
Returns the Spot Date
|
JulianDate |
getStartDate()
Get the epoch date
|
boolean |
initializeCalibrationRun(double dblLeftSlope)
Initialize the Calibration Run with the Left Slope
|
boolean |
IsBasisBootstrapped()
Returns if the inputs are for bootstrapped FX basis
|
int |
numCalibNodes()
Retrieve the number of calibration nodes
|
byte[] |
serialize()
Serialize into a byte array.
|
boolean |
setFlatValue(double dblValue)
Set the flat value across all the nodes
|
boolean |
setNodeValue(int iIndex,
double dblValue)
Set the Value/Slope at the Node specified by the Index
|
getCollectionKeyValueDelimiter, getCollectionMultiLevelKeyDelimiter, getCollectionRecordDelimiter, getFieldDelimiter, getObjectTrailer
public DerivedFXBasis(CurrencyPair cp, JulianDate dtSpot, double dblFXSpot, double[] adblDate, double[] adblFXBasis, boolean bIsFXBasisBootstrapped) throws java.lang.Exception
cp
- Currency PairdtSpot
- Spot DatedblFXSpot
- FX SpotadblDate
- Array of datesadblFXBasis
- Array of FX BasisbIsFXBasisBootstrapped
- True if the inputs are for bootstrapped FX basisjava.lang.Exception
- Thrown if the FXBasis instance cannot be createdpublic DerivedFXBasis(byte[] ab) throws java.lang.Exception
ab
- Byte Arrayjava.lang.Exception
- Thrown if FXBasis cannot be properly de-serializedpublic boolean initializeCalibrationRun(double dblLeftSlope)
Curve
dblLeftSlope
- Left Slopepublic int numCalibNodes()
Curve
public CurrencyPair getCurrencyPair()
FXBasisCurve
getCurrencyPair
in class FXBasisCurve
public JulianDate getSpotDate()
FXBasisCurve
getSpotDate
in class FXBasisCurve
public double getFXSpot()
FXBasisCurve
getFXSpot
in class FXBasisCurve
public boolean IsBasisBootstrapped()
FXBasisCurve
IsBasisBootstrapped
in class FXBasisCurve
public double[] getFullFXFwd(ValuationParams valParam, DiscountCurve dcNum, DiscountCurve dcDenom, boolean bBasisOnDenom, boolean bFwdAsPIP)
FXBasisCurve
getFullFXFwd
in class FXBasisCurve
valParam
- ValuationParamsdcNum
- Discount Curve NumeratordcDenom
- Discount Curve NumeratorbBasisOnDenom
- True if the basis is on the denominatorbFwdAsPIP
- True if the FX Forwards are to represented as PIPpublic boolean setNodeValue(int iIndex, double dblValue)
Curve
iIndex
- Node IndexdblValue
- Node Valuepublic boolean bumpNodeValue(int iIndex, double dblValue)
Curve
iIndex
- node indexdblValue
- node bump valuepublic boolean setFlatValue(double dblValue)
Curve
dblValue
- node valuepublic java.lang.String displayString()
Curve
public double[] getCompQuotes()
Curve
public java.lang.String[] getCompMeasures()
Curve
public double getQuote(java.lang.String strInstr) throws java.lang.Exception
Curve
java.lang.Exception
public JulianDate getNodeDate(int iIndex)
Curve
iIndex
- node indexpublic CalibratableComponent[] getCalibComponents()
Curve
public java.lang.String getName()
Curve
public Curve createParallelShiftedCurve(double dblShift)
Curve
dblShift
- Parallel shiftpublic Curve createTweakedCurve(NodeTweakParams ntp)
Curve
ntp
- Node Tweak Parameterspublic JulianDate getStartDate()
Curve
public byte[] serialize()
Serializer
serialize
in class Serializer
public Serializer deserialize(byte[] ab)
Serializer
deserialize
in class Serializer
public boolean buildInterpolator()
Curve