Source:
<code><START> public void fixedSwapLeg() { <END> PeriodicSchedule accrualSchedule = PeriodicSchedule.builder() .startDate(LocalDate.of(2014, 2, 12)) .endDate(LocalDate.of(2016, 7, 31)) .businessDayAdjustment(BusinessDayAdjustment.of(MODIFIED_FOLLOWING, HolidayCalendars.GBLO)) .frequency(Frequency.P3M) .stubConvention(StubConvention.LONG_INITIAL) .rollConvention(RollConventions.EOM) .build(); PaymentSchedule paymentSchedule = PaymentSchedule.builder() .paymentFrequency(Frequency.P6M) .paymentRelativeTo(PaymentRelativeTo.PERIOD_END) .paymentOffset(DaysAdjustment.ofBusinessDays(2, HolidayCalendars.GBLO)) .compoundingMethod(CompoundingMethod.STRAIGHT) .build(); NotionalSchedule notionalSchedule = NotionalSchedule.builder() .currency(Currency.GBP) .amount(ValueSchedule.of( 1_000_000, ValueStep.ofAbsoluteAmount(LocalDate.of(2015, 1, 31), 2_000_000))) .build(); RateCalculationSwapLeg swapLeg = RateCalculationSwapLeg.builder() .payReceive(PayReceive.PAY) .accrualSchedule(accrualSchedule) .paymentSchedule(paymentSchedule) .notionalSchedule(notionalSchedule) .calculation(FixedRateCalculation.builder() .dayCount(DayCounts.ACT_ACT_ISDA) .rate(ValueSchedule.of( 0.008, ValueStep.ofAbsoluteAmount(LocalDate.of(2015, 1, 31), 0.007))) .build()) .build(); ExpandedSwapLeg expandedLeg = swapLeg.expand(); System.out.println("===== Fixed ====="); System.out.println(JodaBeanSer.PRETTY.jsonWriter().write(swapLeg)); System.out.println(); System.out.println("===== Fixed expanded ====="); System.out.println(JodaBeanSer.PRETTY.jsonWriter().write(expandedLeg)); System.out.println(); }</code><technical_language>Is worth starting absolutely simplest work for fixed float legs - users want try first? For instance, I a variable notional want try. move more complex examples show range of done. moment overwhelm devs</technical_language>

Target:
public void fixedSwapLeg() { PeriodicSchedule accrualSchedule = PeriodicSchedule.builder() .startDate(LocalDate.of(2014, 2, 12)) .endDate(LocalDate.of(2016, 7, 31)) .businessDayAdjustment(BusinessDayAdjustment.of(MODIFIED_FOLLOWING, HolidayCalendars.GBLO)) .frequency(Frequency.P3M) .stubConvention(StubConvention.LONG_INITIAL) .rollConvention(RollConventions.EOM) .build(); PaymentSchedule paymentSchedule = PaymentSchedule.builder() .paymentFrequency(Frequency.P6M) .paymentRelativeTo(PaymentRelativeTo.PERIOD_END) .paymentOffset(DaysAdjustment.ofBusinessDays(2, HolidayCalendars.GBLO)) .compoundingMethod(CompoundingMethod.STRAIGHT) .build(); NotionalSchedule notionalSchedule = NotionalSchedule.of(Currency.GBP, 1_000_000); RateCalculationSwapLeg swapLeg = RateCalculationSwapLeg.builder() .payReceive(PayReceive.PAY) .accrualSchedule(accrualSchedule) .paymentSchedule(paymentSchedule) .notionalSchedule(notionalSchedule) .calculation(FixedRateCalculation.builder() .dayCount(DayCounts.ACT_ACT_ISDA) .rate(ValueSchedule.of( 0.008, ValueStep.ofAbsoluteAmount(LocalDate.of(2015, 1, 31), 0.007))) .build()) .build(); ExpandedSwapLeg expandedLeg = swapLeg.expand(); System.out.println("===== Fixed ====="); System.out.println(JodaBeanSer.PRETTY.jsonWriter().write(swapLeg)); System.out.println(); System.out.println("===== Fixed expanded ====="); System.out.println(JodaBeanSer.PRETTY.jsonWriter().write(expandedLeg)); System.out.println(); }