Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,27 @@ public final class FixedOvernightSwapConventions {
public static final FixedOvernightSwapConvention USD_FIXED_1Y_SOFR_OIS =
FixedOvernightSwapConvention.of(StandardFixedOvernightSwapConventions.USD_FIXED_1Y_SOFR_OIS.getName());

//-------------------------------------------------------------------------
/**
* The 'CHF-FIXED-TERM-SARON-OIS' swap convention.
* <p>
* CHF fixed vs SARON OIS swap for terms less than or equal to one year.
* Both legs pay annually and use day count 'Act/360'.
* The spot date offset is 2 days and the payment date offset is 2 days.
*/
public static final FixedOvernightSwapConvention CHF_FIXED_TERM_SARON_OIS =
FixedOvernightSwapConvention.of(StandardFixedOvernightSwapConventions.CHF_FIXED_TERM_SARON_OIS.getName());

/**
* The 'CHF-FIXED-1Y-SARON-OIS' swap convention.
* <p>
* CHF fixed vs SARON OIS swap for terms greater than one year.
* Both legs pay annually and use day count 'Act/360'.
* The spot date offset is 2 days and the payment date offset is 2 days.
*/
public static final FixedOvernightSwapConvention CHF_FIXED_1Y_SARON_OIS =
FixedOvernightSwapConvention.of(StandardFixedOvernightSwapConventions.CHF_FIXED_1Y_SARON_OIS.getName());

//-------------------------------------------------------------------------
/**
* The 'EUR-FIXED-TERM-EONIA-OIS' swap convention.
Expand Down Expand Up @@ -99,7 +120,7 @@ public final class FixedOvernightSwapConventions {
* <p>
* JPY fixed vs TONAR OIS swap for terms less than or equal to one year.
* Both legs pay once at the end and use day count 'Act/365F'.
* The spot date offset is 2 days and there is no payment date offset.
* The spot date offset is 2 days and the payment date offset is 2 days.
*/
public static final FixedOvernightSwapConvention JPY_FIXED_TERM_TONAR_OIS =
FixedOvernightSwapConvention.of(StandardFixedOvernightSwapConventions.JPY_FIXED_TERM_TONAR_OIS.getName());
Expand All @@ -109,7 +130,7 @@ public final class FixedOvernightSwapConventions {
* <p>
* JPY fixed vs TONAR OIS swap for terms greater than one year.
* Both legs pay annually and use day count 'Act/365F'.
* The spot date offset is 2 days and there is no payment date offset.
* The spot date offset is 2 days and the payment date offset is 2 days.
*/
public static final FixedOvernightSwapConvention JPY_FIXED_1Y_TONAR_OIS =
FixedOvernightSwapConvention.of(StandardFixedOvernightSwapConventions.JPY_FIXED_1Y_TONAR_OIS.getName());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
import static com.opengamma.strata.basics.date.BusinessDayConventions.MODIFIED_FOLLOWING;
import static com.opengamma.strata.basics.date.DayCounts.ACT_360;
import static com.opengamma.strata.basics.date.DayCounts.ACT_365F;
import static com.opengamma.strata.basics.index.OvernightIndices.CHF_SARON;
import static com.opengamma.strata.basics.index.OvernightIndices.EUR_EONIA;
import static com.opengamma.strata.basics.index.OvernightIndices.GBP_SONIA;
import static com.opengamma.strata.basics.index.OvernightIndices.JPY_TONAR;
Expand Down Expand Up @@ -50,6 +51,25 @@ final class StandardFixedOvernightSwapConventions {
public static final FixedOvernightSwapConvention USD_FIXED_1Y_FED_FUND_OIS =
makeConvention("USD-FIXED-1Y-FED-FUND-OIS", USD_FED_FUND, ACT_360, P12M, 2, 2);

//-------------------------------------------------------------------------
/**
* CHF fixed vs SARON OIS swap for terms less than or equal to one year.
* <p>
* Both legs pay annually and use day count 'Act/360'.
* The spot date offset is 2 days and the payment date offset is 2 days.
*/
public static final FixedOvernightSwapConvention CHF_FIXED_TERM_SARON_OIS =
makeConvention("CHF-FIXED-TERM-SARON-OIS", CHF_SARON, ACT_360, TERM, 2, 2);

/**
* CHF fixed vs SARON OIS swap for terms greater than one year.
* <p>
* Both legs pay annually and use day count 'Act/360'.
* The spot date offset is 2 days and the payment date offset is 2 days.
*/
public static final FixedOvernightSwapConvention CHF_FIXED_1Y_SARON_OIS =
makeConvention("CHF-FIXED-1Y-SARON-OIS", CHF_SARON, ACT_360, P12M, 2, 2);

//-------------------------------------------------------------------------
/**
* USD fixed vs SOFR OIS swap for terms greater than one year.
Expand Down Expand Up @@ -103,19 +123,19 @@ final class StandardFixedOvernightSwapConventions {
* JPY fixed vs TONAR OIS swap for terms less than or equal to one year.
* <p>
* Both legs pay once at the end and use day count 'Act/365F'.
* The spot date offset is 2 days and there is no payment date offset.
* The spot date offset is 2 days and the payment date offset is 2 days.
*/
public static final FixedOvernightSwapConvention JPY_FIXED_TERM_TONAR_OIS =
makeConvention("JPY-FIXED-TERM-TONAR-OIS", JPY_TONAR, ACT_365F, TERM, 0, 0);
makeConvention("JPY-FIXED-TERM-TONAR-OIS", JPY_TONAR, ACT_365F, TERM, 2, 2);

/**
* JPY fixed vs TONAR OIS swap for terms greater than one year.
* <p>
* Both legs pay annually and use day count 'Act/365F'.
* The spot date offset is 2 days and there is no payment date offset.
* The spot date offset is 2 days and the payment date offset is 2 days.
*/
public static final FixedOvernightSwapConvention JPY_FIXED_1Y_TONAR_OIS =
makeConvention("JPY-FIXED-1Y-TONAR-OIS", JPY_TONAR, ACT_365F, P12M, 0, 2);
makeConvention("JPY-FIXED-1Y-TONAR-OIS", JPY_TONAR, ACT_365F, P12M, 2, 2);

//-------------------------------------------------------------------------
// build conventions
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,13 @@ public static Object[][] data_spot_lag() {
return new Object[][] {
{FixedOvernightSwapConventions.USD_FIXED_TERM_FED_FUND_OIS, 2},
{FixedOvernightSwapConventions.USD_FIXED_1Y_FED_FUND_OIS, 2},
{FixedOvernightSwapConventions.CHF_FIXED_TERM_SARON_OIS, 2},
{FixedOvernightSwapConventions.CHF_FIXED_1Y_SARON_OIS, 2},
{FixedOvernightSwapConventions.EUR_FIXED_TERM_EONIA_OIS, 2},
{FixedOvernightSwapConventions.EUR_FIXED_1Y_EONIA_OIS, 2},
{FixedOvernightSwapConventions.GBP_FIXED_TERM_SONIA_OIS, 0},
{FixedOvernightSwapConventions.GBP_FIXED_1Y_SONIA_OIS, 0},
{FixedOvernightSwapConventions.JPY_FIXED_TERM_TONAR_OIS, 0},
{FixedOvernightSwapConventions.JPY_FIXED_TERM_TONAR_OIS, 2},
{FixedOvernightSwapConventions.JPY_FIXED_1Y_TONAR_OIS, 2},
};
}
Expand All @@ -62,6 +64,8 @@ public static Object[][] data_period() {
return new Object[][] {
{FixedOvernightSwapConventions.USD_FIXED_TERM_FED_FUND_OIS, Frequency.TERM},
{FixedOvernightSwapConventions.USD_FIXED_1Y_FED_FUND_OIS, Frequency.P12M},
{FixedOvernightSwapConventions.CHF_FIXED_TERM_SARON_OIS, Frequency.TERM},
{FixedOvernightSwapConventions.CHF_FIXED_1Y_SARON_OIS, Frequency.P12M},
{FixedOvernightSwapConventions.EUR_FIXED_TERM_EONIA_OIS, Frequency.TERM},
{FixedOvernightSwapConventions.EUR_FIXED_1Y_EONIA_OIS, Frequency.P12M},
{FixedOvernightSwapConventions.GBP_FIXED_TERM_SONIA_OIS, Frequency.TERM},
Expand All @@ -88,6 +92,8 @@ public static Object[][] data_day_count() {
return new Object[][] {
{FixedOvernightSwapConventions.USD_FIXED_TERM_FED_FUND_OIS, DayCounts.ACT_360},
{FixedOvernightSwapConventions.USD_FIXED_1Y_FED_FUND_OIS, DayCounts.ACT_360},
{FixedOvernightSwapConventions.CHF_FIXED_TERM_SARON_OIS, DayCounts.ACT_360},
{FixedOvernightSwapConventions.CHF_FIXED_1Y_SARON_OIS, DayCounts.ACT_360},
{FixedOvernightSwapConventions.EUR_FIXED_TERM_EONIA_OIS, DayCounts.ACT_360},
{FixedOvernightSwapConventions.EUR_FIXED_1Y_EONIA_OIS, DayCounts.ACT_360},
{FixedOvernightSwapConventions.GBP_FIXED_TERM_SONIA_OIS, DayCounts.ACT_365F},
Expand All @@ -108,6 +114,8 @@ public static Object[][] data_float_leg() {
return new Object[][] {
{FixedOvernightSwapConventions.USD_FIXED_TERM_FED_FUND_OIS, OvernightIndices.USD_FED_FUND},
{FixedOvernightSwapConventions.USD_FIXED_1Y_FED_FUND_OIS, OvernightIndices.USD_FED_FUND},
{FixedOvernightSwapConventions.CHF_FIXED_TERM_SARON_OIS, OvernightIndices.CHF_SARON},
{FixedOvernightSwapConventions.CHF_FIXED_1Y_SARON_OIS, OvernightIndices.CHF_SARON},
{FixedOvernightSwapConventions.EUR_FIXED_TERM_EONIA_OIS, OvernightIndices.EUR_EONIA},
{FixedOvernightSwapConventions.EUR_FIXED_1Y_EONIA_OIS, OvernightIndices.EUR_EONIA},
{FixedOvernightSwapConventions.GBP_FIXED_TERM_SONIA_OIS, OvernightIndices.GBP_SONIA},
Expand All @@ -128,6 +136,8 @@ public static Object[][] data_day_convention() {
return new Object[][] {
{FixedOvernightSwapConventions.USD_FIXED_TERM_FED_FUND_OIS, BusinessDayConventions.MODIFIED_FOLLOWING},
{FixedOvernightSwapConventions.USD_FIXED_1Y_FED_FUND_OIS, BusinessDayConventions.MODIFIED_FOLLOWING},
{FixedOvernightSwapConventions.CHF_FIXED_TERM_SARON_OIS, BusinessDayConventions.MODIFIED_FOLLOWING},
{FixedOvernightSwapConventions.CHF_FIXED_1Y_SARON_OIS, BusinessDayConventions.MODIFIED_FOLLOWING},
{FixedOvernightSwapConventions.EUR_FIXED_TERM_EONIA_OIS, BusinessDayConventions.MODIFIED_FOLLOWING},
{FixedOvernightSwapConventions.EUR_FIXED_1Y_EONIA_OIS, BusinessDayConventions.MODIFIED_FOLLOWING},
{FixedOvernightSwapConventions.GBP_FIXED_TERM_SONIA_OIS, BusinessDayConventions.MODIFIED_FOLLOWING},
Expand All @@ -147,6 +157,7 @@ public void test_day_convention(FixedOvernightSwapConvention convention, Busines
public static Object[][] data_stub_on() {
return new Object[][] {
{FixedOvernightSwapConventions.USD_FIXED_1Y_FED_FUND_OIS, Tenor.TENOR_18M},
{FixedOvernightSwapConventions.CHF_FIXED_1Y_SARON_OIS, Tenor.TENOR_18M},
{FixedOvernightSwapConventions.EUR_FIXED_1Y_EONIA_OIS, Tenor.TENOR_18M},
{FixedOvernightSwapConventions.GBP_FIXED_1Y_SONIA_OIS, Tenor.TENOR_18M},
{FixedOvernightSwapConventions.JPY_FIXED_1Y_TONAR_OIS, Tenor.TENOR_18M},
Expand Down