@Override public NotionalExchange build() { return new NotionalExchange( payment); }
/** * Obtains an instance from the payment. * * @param payment the payment to be made * @return the notional exchange */ public static NotionalExchange of(Payment payment) { return new NotionalExchange(payment); }
/** * Obtains an instance from the amount and date. * * @param paymentAmount the amount of the notional exchange * @param paymentDate the date that the payment is made * @return the notional exchange */ public static NotionalExchange of(CurrencyAmount paymentAmount, LocalDate paymentDate) { return new NotionalExchange(Payment.of(paymentAmount, paymentDate)); }