suncertify.date
Class DateClass
java.lang.Object
|
+--suncertify.date.DateClass
- public class DateClass
- extends java.lang.Object
The DateClass is the public class which handles all the date
operations for the Fly by Nights Reservations System.
Constructor Summary |
DateClass()
The class constructor. |
Method Summary |
static java.lang.String |
getDateForDay(java.lang.String day)
|
static java.lang.String |
getDayOfDate(java.lang.String dateStr)
The static method to get the "Day" corresponding to any "Date". |
static java.lang.String[] |
nextWkDates()
Find the list of all dates in the next week inclusive of TODAY |
static void |
validateDate(java.lang.String date)
The method to validate the date against a certian format. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
DateClass
public DateClass()
- The class constructor.
getDayOfDate
public static java.lang.String getDayOfDate(java.lang.String dateStr)
throws DateException
- The static method to get the "Day" corresponding to any "Date".
- Parameters:
dateStr:
- The date as a string whose Day is to be worked out.- Returns:
- String: The day of the date
getDateForDay
public static java.lang.String getDateForDay(java.lang.String day)
nextWkDates
public static java.lang.String[] nextWkDates()
- Find the list of all dates in the next week inclusive of TODAY
- Returns:
- String[] : The list of dates of next week.
validateDate
public static void validateDate(java.lang.String date)
throws DateException
- The method to validate the date against a certian format.
- Parameters:
date
- : The date to be validated- Throws:
- DateException - : when the date is not of the desired format.