Class CdsCalibrationTrade
- java.lang.Object
-
- com.opengamma.strata.product.credit.CdsCalibrationTrade
-
- All Implemented Interfaces:
CalculationTarget
,PortfolioItem
,Trade
,Serializable
,org.joda.beans.Bean
,org.joda.beans.ImmutableBean
public final class CdsCalibrationTrade extends Object implements Trade, org.joda.beans.ImmutableBean, Serializable
A trade in a single-name credit default swap (CDS) used for credit curve calibration.The CDS trade and market quote are stored in this class.
CdsTrade
andResolvedCdsTrade
should be used for pricing.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
CdsCalibrationTrade.Meta
The meta-bean forCdsCalibrationTrade
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
TradeInfo
getInfo()
Gets the standard trade information.CdsQuote
getQuote()
Gets the CDS quote.CdsTrade
getUnderlyingTrade()
Gets the underlying CDS trade.int
hashCode()
static CdsCalibrationTrade.Meta
meta()
The meta-bean forCdsCalibrationTrade
.CdsCalibrationTrade.Meta
metaBean()
static CdsCalibrationTrade
of(CdsTrade trade, CdsQuote quote)
Creates an instance.PortfolioItemSummary
summarize()
Summarizes the portfolio item.String
toString()
CdsCalibrationTrade
withInfo(PortfolioItemInfo info)
Returns an instance with the specified info.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.opengamma.strata.product.PortfolioItem
getId
-
-
-
-
Method Detail
-
of
public static CdsCalibrationTrade of(CdsTrade trade, CdsQuote quote)
Creates an instance.- Parameters:
trade
- the tradequote
- the quote- Returns:
- the instance
-
getInfo
public TradeInfo getInfo()
Description copied from interface:Trade
Gets the standard trade information.All trades contain this standard set of information.
- Specified by:
getInfo
in interfacePortfolioItem
- Specified by:
getInfo
in interfaceTrade
- Returns:
- the trade information
-
withInfo
public CdsCalibrationTrade withInfo(PortfolioItemInfo info)
Description copied from interface:Trade
Returns an instance with the specified info.- Specified by:
withInfo
in interfacePortfolioItem
- Specified by:
withInfo
in interfaceTrade
- Parameters:
info
- the new info- Returns:
- the instance with the specified info
-
summarize
public PortfolioItemSummary summarize()
Description copied from interface:PortfolioItem
Summarizes the portfolio item.This provides a summary, including a human readable description.
- Specified by:
summarize
in interfacePortfolioItem
- Specified by:
summarize
in interfaceTrade
- Returns:
- the summary of the item
-
meta
public static CdsCalibrationTrade.Meta meta()
The meta-bean forCdsCalibrationTrade
.- Returns:
- the meta-bean, not null
-
metaBean
public CdsCalibrationTrade.Meta metaBean()
- Specified by:
metaBean
in interfaceorg.joda.beans.Bean
-
getUnderlyingTrade
public CdsTrade getUnderlyingTrade()
Gets the underlying CDS trade.- Returns:
- the value of the property, not null
-
getQuote
public CdsQuote getQuote()
Gets the CDS quote.- Returns:
- the value of the property, not null
-
-