CouponONSpreadSimplifiedDefinition extends CouponDefinition { public static CouponONSpreadSimplifiedDefinition from(final IndexON index, final ZonedDateTime settlementDate, final Period tenor, final double notional, final double spread, final int settlementDays, final BusinessDayConvention businessDayConvention, final boolean isEOM, final Calendar calendar) { final ZonedDateTime endFixingPeriodDate = ScheduleCalculator.getAdjustedDate(settlementDate, tenor, businessDayConvention, calendar, isEOM); return CouponONSpreadSimplifiedDefinition.from(index, settlementDate, endFixingPeriodDate, notional, spread, settlementDays, calendar); } CouponONSpreadSimplifiedDefinition(final Currency currency, final ZonedDateTime paymentDate, final ZonedDateTime accrualStartDate,
      final ZonedDateTime accrualEndDate, final double paymentAccrualFactor, final double notional, final IndexON index, final ZonedDateTime fixingPeriodStartDate,
      final ZonedDateTime fixingPeriodEndDate, final double fixingPeriodAccrualFactor, final double spread); static CouponONSpreadSimplifiedDefinition from(final IndexON index, final ZonedDateTime settlementDate, final Period tenor, final double notional, final double spread,
      final int settlementDays, final BusinessDayConvention businessDayConvention, final boolean isEOM, final Calendar calendar); static CouponONSpreadSimplifiedDefinition from(final IndexON index, final ZonedDateTime settlementDate, final ZonedDateTime endFixingPeriodDate,
      final double notional, final double spread, final int settlementDays, final Calendar calendar); IndexON getIndex(); ZonedDateTime getFixingPeriodStartDate(); ZonedDateTime getFixingPeriodEndDate(); double getFixingPeriodAccrualFactor(); double getSpread(); double getSpreadAmount(); @Override int hashCode(); @Override boolean equals(final Object obj); @Override CouponONSpread toDerivative(final ZonedDateTime date); @Override V accept(final InstrumentDefinitionVisitor<U, V> visitor, final U data); @Override V accept(final InstrumentDefinitionVisitor<?, V> visitor);  }
@Test public void from1() { final CouponONSpreadSimplifiedDefinition cpnFrom = CouponONSpreadSimplifiedDefinition.from(EUR_OIS, SPOT_DATE, EUR_CPN_TENOR, NOTIONAL, SPREAD, EUR_SETTLEMENT_DAYS, EUR_BUSINESS_DAY, EUR_IS_EOM, EUR_CALENDAR); assertEquals("CouponOISSimplified definition: from", cpnFrom, EONIA_COUPON_DEFINITION); }
@Test public void from2() { final CouponONSpreadSimplifiedDefinition cpnFrom = CouponONSpreadSimplifiedDefinition.from(EUR_OIS, SPOT_DATE, END_ACCRUAL_DATE, NOTIONAL, SPREAD, EUR_SETTLEMENT_DAYS, EUR_CALENDAR); assertEquals("CouponOISSimplified definition: from", cpnFrom, EONIA_COUPON_DEFINITION); }