|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sourceforge.fixagora.basis.shared.control.analysis.AnalysisDate
public class AnalysisDate
The Class AnalysisDate.
| Constructor Summary | |
|---|---|
AnalysisDate(AnalysisDate copy)
Instantiates a new analysis date. |
|
AnalysisDate(java.util.Date date,
int basis)
Instantiates a new analysis date. |
|
| Method Summary | |
|---|---|
void |
addMonths(int monthCount)
Adds the months. |
void |
addMonthsUnadjusted(int monthCount)
Adds the months unadjusted. |
boolean |
eq(AnalysisDate compareDate)
Eq. |
static double |
getAverageYearLength(int startYear,
int endYear)
Gets the average year length. |
AnalysisDate |
getDate()
Gets the date. |
int |
getDay()
Gets the day. |
static int |
getDaysInYear(AnalysisDate date,
int basis)
Gets the days in year. |
static int |
getDaysInYears(int fromYear,
int toYear)
Gets the days in years. |
static int |
getDiff(AnalysisDate startDate,
AnalysisDate endDate)
Gets the diff. |
static int |
getDiff(AnalysisDate startDate,
AnalysisDate endDate,
boolean forceThirty)
Gets the diff. |
static int |
getLastDayOfMonth(int month,
int year)
Gets the last day of month. |
static int |
getModifiedDiff(AnalysisDate startDate,
AnalysisDate endDate,
boolean modifyBothDates,
int basis)
Gets the modified diff. |
int |
getMonth()
Gets the month. |
static double |
getOddFDiff(AnalysisDate startDate,
AnalysisDate endDate,
int basis)
Gets the odd f diff. |
int |
getOriginalDay()
Gets the original day. |
int |
getYear()
Gets the year. |
static double |
getYearfrac(AnalysisDate startDate,
AnalysisDate endDate,
int basis)
Gets the yearfrac. |
boolean |
gt(AnalysisDate compareDate)
Gt. |
boolean |
isLastDay()
Checks if is last day. |
static boolean |
isLeapYear(int i)
Checks if is leap year. |
boolean |
isThirtyDays()
Checks if is thirty days. |
boolean |
le(AnalysisDate compareDate)
Le. |
boolean |
lt(AnalysisDate compareDate)
Lt. |
void |
setDay(int day)
Sets the day. |
void |
setLastDay(boolean lastDay)
Sets the last day. |
void |
setMonth(int month)
Sets the month. |
void |
setOriginalday(int originalday)
Sets the originalday. |
void |
setYear(int year)
Sets the year. |
static boolean |
shouldCountFeb29(AnalysisDate startDate,
AnalysisDate endDate)
Should count feb29. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AnalysisDate(java.util.Date date,
int basis)
date - the datebasis - the basispublic AnalysisDate(AnalysisDate copy)
copy - the copy| Method Detail |
|---|
public static int getLastDayOfMonth(int month,
int year)
month - the monthyear - the year
public static boolean isLeapYear(int i)
i - the i
public boolean lt(AnalysisDate compareDate)
compareDate - the compare date
public boolean le(AnalysisDate compareDate)
compareDate - the compare date
public boolean eq(AnalysisDate compareDate)
compareDate - the compare date
public boolean gt(AnalysisDate compareDate)
compareDate - the compare date
public void addMonths(int monthCount)
monthCount - the month count
public static int getDiff(AnalysisDate startDate,
AnalysisDate endDate)
startDate - the start dateendDate - the end date
public static int getDiff(AnalysisDate startDate,
AnalysisDate endDate,
boolean forceThirty)
startDate - the start dateendDate - the end dateforceThirty - the force thirty
public static int getDaysInYears(int fromYear,
int toYear)
fromYear - the from yeartoYear - the to year
public int getOriginalDay()
public void setOriginalday(int originalday)
originalday - the new originaldaypublic int getDay()
public void setDay(int day)
day - the new daypublic void setLastDay(boolean lastDay)
lastDay - the new last daypublic int getMonth()
public void setMonth(int month)
month - the new monthpublic int getYear()
public void setYear(int year)
year - the new yearpublic boolean isThirtyDays()
public AnalysisDate getDate()
public static int getDaysInYear(AnalysisDate date,
int basis)
throws java.lang.Exception
date - the datebasis - the basis
java.lang.Exception - the exceptionpublic boolean isLastDay()
public static boolean shouldCountFeb29(AnalysisDate startDate,
AnalysisDate endDate)
startDate - the start dateendDate - the end date
public static double getYearfrac(AnalysisDate startDate,
AnalysisDate endDate,
int basis)
startDate - the start dateendDate - the end datebasis - the basis
public static double getAverageYearLength(int startYear,
int endYear)
startYear - the start yearendYear - the end year
public static int getModifiedDiff(AnalysisDate startDate,
AnalysisDate endDate,
boolean modifyBothDates,
int basis)
startDate - the start dateendDate - the end datemodifyBothDates - the modify both datesbasis - the basis
public void addMonthsUnadjusted(int monthCount)
monthCount - the month count
public static double getOddFDiff(AnalysisDate startDate,
AnalysisDate endDate,
int basis)
startDate - the start dateendDate - the end datebasis - the basis
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||