net.objectlab.kit.datecalc.common
Enum PeriodCountBasis

Package class diagram package PeriodCountBasis
java.lang.Object
  extended by java.lang.Enum<PeriodCountBasis>
      extended by net.objectlab.kit.datecalc.common.PeriodCountBasis
All Implemented Interfaces:
Serializable, Comparable<PeriodCountBasis>

public enum PeriodCountBasis
extends Enum<PeriodCountBasis>

Defines some standard Day Count bases.

To read about the most common Day Count Conventions, you can refer to the following document.

Version:
$Revision: 300 $ $Date: 2010-03-18 16:09:14 -0400 (Thu, 18 Mar 2010) $
Author:
Benoit Xhenseval, $LastChangedBy: benoitx $

Enum Constant Summary
ACT_360
          Actual/360, known in the United States as money market basis, has a day count fraction equal to the number of days between the payment dates, divided by 360.
ACT_365
          Actual/365(Fixed), known as bond basis in the United States, means that the day count fraction is equal to the number of days between the last payment date and the next date divided by 365.
ACT_ACT
          Actual/Actual, means that the numerator is the number of days between the two dates.
CONV_30_360
          30/360, means that day count fractions are calculated assuming 30 day months and 360 days in a year.
CONV_360E_ISDA
          30E/360, means that day count fractions are calculated assuming 30 day months and 360 days in a year.
CONV_360E_ISMA
          30E+/360, means that day count fractions are calculated assuming 30 day months and 360 days in a year.
 
Method Summary
static PeriodCountBasis valueOf(String name)
          Returns the enum constant of this type with the specified name.
static PeriodCountBasis[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

CONV_30_360

public static final PeriodCountBasis CONV_30_360
30/360, means that day count fractions are calculated assuming 30 day months and 360 days in a year. The second date is only adjusted if the first date is on the 31st of a month.


CONV_360E_ISDA

public static final PeriodCountBasis CONV_360E_ISDA
30E/360, means that day count fractions are calculated assuming 30 day months and 360 days in a year. In this case, the second date is always adjusted to the 30th, if it is the 31st.


CONV_360E_ISMA

public static final PeriodCountBasis CONV_360E_ISMA
30E+/360, means that day count fractions are calculated assuming 30 day months and 360 days in a year. If the second date is on the 31st, it is adjusted to the 30th and a second month is incremented by one.


ACT_ACT

public static final PeriodCountBasis ACT_ACT
Actual/Actual, means that the numerator is the number of days between the two dates. The denominator is the actual number of days in the coupon period multiplied by the coupon frequency. This is mainly relates to bonds. This normally results in day count factors of 1.0 for annual coupons, 0.5 for semi annual coupons and 0.25 for quarterly coupons.


ACT_360

public static final PeriodCountBasis ACT_360
Actual/360, known in the United States as money market basis, has a day count fraction equal to the number of days between the payment dates, divided by 360.


ACT_365

public static final PeriodCountBasis ACT_365
Actual/365(Fixed), known as bond basis in the United States, means that the day count fraction is equal to the number of days between the last payment date and the next date divided by 365.

Method Detail

values

public static PeriodCountBasis[] 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 (PeriodCountBasis c : PeriodCountBasis.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static PeriodCountBasis 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 name
NullPointerException - if the argument is null


Copyright © 2006-2010 Appendium - Portfolio Financing Platform. All Rights Reserved.