class CouponFixedFxResetDiscountingMethod {

  public MultipleCurrencyAmount presentValue(final CouponFixedFxReset coupon, 
      final MulticurveProviderInterface multicurve) {
    Validate.notNull(coupon, "Coupon");
    Validate.notNull(multicurve, "multicurve");
    Currency ccyPayment = coupon.getCurrency();
    Currency ccyReference = coupon.getReferenceCurrency();
    double tp = coupon.getPaymentTime();
    double t0 = coupon.getFxDeliveryTime();
    double todayFxRate = multicurve.getFxRate(ccyReference, ccyPayment);
    double amount = coupon.paymentAmount(todayFxRate);
    double dfCcyPaymentAtPayment = multicurve.getDiscountFactor(ccyPayment, tp);
    double dfCcyReferenceAtDelivery = multicurve.getDiscountFactor(ccyReference, t0);
    double dfCcyPaymentAtDelivery = multicurve.getDiscountFactor(ccyPayment, t0);
    double pv = amount * dfCcyPaymentAtPayment * dfCcyReferenceAtDelivery / dfCcyPaymentAtDelivery;
    return MultipleCurrencyAmount.of(ccyPayment, pv);
  }

  private  CouponFixedFxResetDiscountingMethod();

}