class DiscountingOvernightFutureTradePricer {

  CurrencyAmount presentValue(ResolvedOvernightFutureTrade trade, double currentPrice, double referencePrice) {
    ResolvedOvernightFuture future = trade.getProduct();
    double priceIndex = productPricer.marginIndex(future, currentPrice);
    double referenceIndex = productPricer.marginIndex(future, referencePrice);
    double pv = (priceIndex - referenceIndex) * trade.getQuantity();
    return CurrencyAmount.of(future.getCurrency(), pv);
  }

  public  DiscountingOvernightFutureTradePricer(
      DiscountingOvernightFutureProductPricer productPricer);

}