YieldCurveWithBlackForexTermStructureBundle extends ForexOptionDataBundle<BlackForexTermStructureParameters> { @Override public YieldCurveWithBlackForexTermStructureBundle with(final YieldCurveBundle ycBundle) { return new YieldCurveWithBlackForexTermStructureBundle(ycBundle, getVolatilityModel(), getCurrencyPair()); } YieldCurveWithBlackForexTermStructureBundle(final YieldCurveBundle ycBundle, final BlackForexTermStructureParameters termStructure, final Pair<Currency, Currency> currencyPair); static YieldCurveWithBlackForexTermStructureBundle from(final YieldCurveBundle ycBundle, final BlackForexTermStructureParameters termStructure, final Pair<Currency, Currency> currencyPair); @Override YieldCurveWithBlackForexTermStructureBundle copy(); @Override YieldCurveWithBlackForexTermStructureBundle with(final YieldCurveBundle ycBundle); @Override YieldCurveWithBlackForexTermStructureBundle with(final BlackForexTermStructureParameters volatilityModel);  }
@Test public void testBuilders() { final YieldCurveWithBlackForexTermStructureBundle fxData = new YieldCurveWithBlackForexTermStructureBundle(CURVES, VOLS, CCYS); assertEquals(FX_DATA, fxData); YieldCurveWithBlackForexTermStructureBundle other = fxData.with(TestsDataSetsForex.createCurvesForex2()); assertEquals(FX_DATA, fxData); assertFalse(other.equals(fxData)); other = FX_DATA.with(new BlackForexTermStructureParameters(InterpolatedDoublesCurve.fromSorted(NODES, VOL, LINEAR_FLAT))); assertEquals(FX_DATA, fxData); assertFalse(other.equals(fxData)); }