Enum CapitalIndexedBondYieldConvention
- java.lang.Object
-
- java.lang.Enum<CapitalIndexedBondYieldConvention>
-
- com.opengamma.strata.product.bond.CapitalIndexedBondYieldConvention
-
- All Implemented Interfaces:
Named
,NamedEnum
,Serializable
,Comparable<CapitalIndexedBondYieldConvention>
public enum CapitalIndexedBondYieldConvention extends Enum<CapitalIndexedBondYieldConvention> implements NamedEnum
A convention defining accrued interest calculation type for inflation bond securities.Yield of a bond security is a conventional number representing the internal rate of return of standardized cash flows. When calculating accrued interest, it is necessary to use a formula specific to each yield convention. Accordingly, the computation of price, convexity and duration from the yield should be based on this yield convention.
"Inflation Instruments: Swap Zero-coupon, Year-on-year and Bonds."
-
-
Enum Constant Summary
Enum Constants Enum Constant Description GB_IL_BOND
The UK real yield convention.GB_IL_FLOAT
The UK real yield convention.JP_IL_COMPOUND
The Japan compound yield convention for inflation index bond.JP_IL_SIMPLE
The Japan simple yield convention for inflation index bond.US_IL_REAL
The US real yield convention.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static CapitalIndexedBondYieldConvention
of(String name)
Obtains an instance from the specified name.String
toString()
Returns the formatted name of the type.static CapitalIndexedBondYieldConvention
valueOf(String name)
Returns the enum constant of this type with the specified name.static CapitalIndexedBondYieldConvention[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
US_IL_REAL
public static final CapitalIndexedBondYieldConvention US_IL_REAL
The US real yield convention. Used for TIPS (see Federal Register Vol. 69, N0. 170, p 53623).
-
GB_IL_FLOAT
public static final CapitalIndexedBondYieldConvention GB_IL_FLOAT
The UK real yield convention. Used for inflation linked GILTS.
-
GB_IL_BOND
public static final CapitalIndexedBondYieldConvention GB_IL_BOND
The UK real yield convention. Used for UK inflation linked corporate bond.
-
JP_IL_SIMPLE
public static final CapitalIndexedBondYieldConvention JP_IL_SIMPLE
The Japan simple yield convention for inflation index bond.
-
JP_IL_COMPOUND
public static final CapitalIndexedBondYieldConvention JP_IL_COMPOUND
The Japan compound yield convention for inflation index bond.
-
-
Method Detail
-
values
public static CapitalIndexedBondYieldConvention[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (CapitalIndexedBondYieldConvention c : CapitalIndexedBondYieldConvention.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static CapitalIndexedBondYieldConvention valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
of
public static CapitalIndexedBondYieldConvention of(String name)
Obtains an instance from the specified name.Parsing handles the mixed case form produced by
toString()
and the upper and lower case variants of the enum constant name.- Parameters:
name
- the name to parse- Returns:
- the type
- Throws:
IllegalArgumentException
- if the name is not known
-
toString
public String toString()
Returns the formatted name of the type.- Overrides:
toString
in classEnum<CapitalIndexedBondYieldConvention>
- Returns:
- the formatted string representing the type
-
-