Class DiscountingBulletPaymentTradePricer
- java.lang.Object
-
- com.opengamma.strata.pricer.payment.DiscountingBulletPaymentTradePricer
-
public class DiscountingBulletPaymentTradePricer extends Object
Pricer for for bullet payment trades.This provides the ability to price
ResolvedBulletPaymentTrade
. The trade is priced by discounting the underlying payment.
-
-
Field Summary
Fields Modifier and Type Field Description static DiscountingBulletPaymentTradePricer
DEFAULT
Default implementation.
-
Constructor Summary
Constructors Constructor Description DiscountingBulletPaymentTradePricer(DiscountingPaymentPricer paymentPricer)
Creates an instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CashFlows
cashFlows(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Calculates the future cash flow of the bullet payment trade.CurrencyAmount
currencyExposure(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Calculates the currency exposure of the bullet payment trade.CurrencyAmount
currentCash(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Calculates the current cash of the bullet payment trade.ExplainMap
explainPresentValue(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Explains the present value of the bullet payment product.DiscountingPaymentPricer
getPaymentPricer()
Gets the underlying payment pricer.CurrencyAmount
presentValue(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Calculates the present value of the bullet payment trade.PointSensitivities
presentValueSensitivity(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Calculates the present value sensitivity of the bullet payment trade.
-
-
-
Field Detail
-
DEFAULT
public static final DiscountingBulletPaymentTradePricer DEFAULT
Default implementation.
-
-
Constructor Detail
-
DiscountingBulletPaymentTradePricer
public DiscountingBulletPaymentTradePricer(DiscountingPaymentPricer paymentPricer)
Creates an instance.- Parameters:
paymentPricer
- the pricer forPayment
-
-
Method Detail
-
getPaymentPricer
public DiscountingPaymentPricer getPaymentPricer()
Gets the underlying payment pricer.- Returns:
- the payment pricer
-
presentValue
public CurrencyAmount presentValue(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Calculates the present value of the bullet payment trade.The present value of the trade is the value on the valuation date. This is the discounted forecast value.
- Parameters:
trade
- the tradeprovider
- the provider- Returns:
- the present value of the trade
-
explainPresentValue
public ExplainMap explainPresentValue(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Explains the present value of the bullet payment product.This returns explanatory information about the calculation.
- Parameters:
trade
- the tradeprovider
- the provider- Returns:
- the explanatory information
-
presentValueSensitivity
public PointSensitivities presentValueSensitivity(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Calculates the present value sensitivity of the bullet payment trade.The present value sensitivity of the trade is the sensitivity of the present value to the underlying curves.
- Parameters:
trade
- the tradeprovider
- the provider- Returns:
- the point sensitivity of the present value
-
cashFlows
public CashFlows cashFlows(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Calculates the future cash flow of the bullet payment trade.There is only one cash flow on the payment date for the bullet payment trade.
- Parameters:
trade
- the tradeprovider
- the provider- Returns:
- the cash flows
-
currencyExposure
public CurrencyAmount currencyExposure(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Calculates the currency exposure of the bullet payment trade.- Parameters:
trade
- the tradeprovider
- the provider- Returns:
- the currency exposure
-
currentCash
public CurrencyAmount currentCash(ResolvedBulletPaymentTrade trade, BaseProvider provider)
Calculates the current cash of the bullet payment trade.- Parameters:
trade
- the tradeprovider
- the provider- Returns:
- the current cash
-
-