|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectjava.util.Calendar
java.util.GregorianCalendar
gov.usda.gdpc.util.Calendar
| Field Summary |
| Fields inherited from class java.util.GregorianCalendar |
AD, BC |
| Fields inherited from class java.util.Calendar |
AM, AM_PM, APRIL, areFieldsSet, AUGUST, DATE, DAY_OF_MONTH, DAY_OF_WEEK, DAY_OF_WEEK_IN_MONTH, DAY_OF_YEAR, DECEMBER, DST_OFFSET, ERA, FEBRUARY, FIELD_COUNT, fields, FRIDAY, HOUR, HOUR_OF_DAY, isSet, isTimeSet, JANUARY, JULY, JUNE, MARCH, MAY, MILLISECOND, MINUTE, MONDAY, MONTH, NOVEMBER, OCTOBER, PM, SATURDAY, SECOND, SEPTEMBER, SUNDAY, THURSDAY, time, TUESDAY, UNDECIMBER, WEDNESDAY, WEEK_OF_MONTH, WEEK_OF_YEAR, YEAR, ZONE_OFFSET |
| Constructor Summary | |
Calendar()
Constructs a default Calendar using the current time in the default time zone with the default locale. |
|
Calendar(int year,
int month,
int date)
Constructs a Calendar with the given date set in the default time zone with the default locale. |
|
Calendar(int year,
int month,
int date,
int hour,
int minute)
Constructs a Calendar with the given date and time set for the default time zone with the default locale. |
|
Calendar(int year,
int month,
int date,
int hour,
int minute,
int second)
Constructs a Calendar with the given date and time set for the default time zone with the default locale. |
|
Calendar(java.util.Locale aLocale)
Constructs a Calendar based on the current time in the default time zone with the given locale. |
|
Calendar(java.util.TimeZone zone)
Constructs a Calendar based on the current time in the given time zone with the default locale. |
|
Calendar(java.util.TimeZone zone,
java.util.Locale aLocale)
Constructs a GregorianCalendar based on the current time in the given time zone with the given locale. |
|
| Method Summary | |
int |
compareTo(java.lang.Object o)
Compares this object with the specified object for order. |
java.lang.String |
getDateTimeString()
Returns date and time of this calendar as a string. |
java.lang.String |
toString()
Returns string representation of this calendar. |
java.lang.String |
xmlString()
|
| Methods inherited from class java.util.GregorianCalendar |
add, computeFields, computeTime, equals, getActualMaximum, getActualMinimum, getGreatestMinimum, getGregorianChange, getLeastMaximum, getMaximum, getMinimum, hashCode, isLeapYear, roll, roll, setGregorianChange |
| Methods inherited from class java.util.Calendar |
after, before, clear, clear, clone, complete, get, getAvailableLocales, getFirstDayOfWeek, getInstance, getInstance, getInstance, getInstance, getMinimalDaysInFirstWeek, getTime, getTimeInMillis, getTimeZone, internalGet, isLenient, isSet, set, set, set, set, setFirstDayOfWeek, setLenient, setMinimalDaysInFirstWeek, setTime, setTimeInMillis, setTimeZone |
| Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public Calendar()
public Calendar(int year,
int month,
int date)
public Calendar(int year,
int month,
int date,
int hour,
int minute)
public Calendar(int year,
int month,
int date,
int hour,
int minute,
int second)
public Calendar(java.util.Locale aLocale)
public Calendar(java.util.TimeZone zone)
public Calendar(java.util.TimeZone zone,
java.util.Locale aLocale)
| Method Detail |
public java.lang.String toString()
public java.lang.String getDateTimeString()
public int compareTo(java.lang.Object o)
In the foregoing description, the notation sgn(expression) designates the mathematical signum function, which is defined to return one of -1, 0, or 1 according to whether the value of expression is negative, zero or positive. The implementor must ensure sgn(x.compareTo(y)) == -sgn(y.compareTo(x)) for all x and y. (This implies that x.compareTo(y) must throw an exception iff y.compareTo(x) throws an exception.)
The implementor must also ensure that the relation is transitive: (x.compareTo(y)>0 && y.compareTo(z)>0) implies x.compareTo(z)>0.
Finally, the implementer must ensure that x.compareTo(y)==0 implies that sgn(x.compareTo(z)) == sgn(y.compareTo(z)), for all z.
It is strongly recommended, but not strictly required that (x.compareTo(y)==0) == (x.equals(y)). Generally speaking, any class that implements the Comparable interface and violates this condition should clearly indicate this fact. The recommended language is "Note: this class has a natural ordering that is inconsistent with equals."
compareTo in interface java.lang.Comparableo - the Object to be compared.
java.lang.ClassCastException - if the specified object's type prevents it
from being compared to this Object.public java.lang.String xmlString()
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||