Note
Unlike GregorianCalendar, all computations performed by this class occur in the pure proleptic GregorianCalendar.
| Modifier and Type | Field and Description |
|---|---|
| private static final int[] | |
| private static final int | |
| private static final int | |
| public static final long | |
| public static final int | |
| public static final int | |
| public static final int | |
| public static final int | |
| public static final long | |
| private static final int[] |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public static int | Returns: the day of weekthe 1970-epoch day (integral value) day)Return the day of week on the 1970-epoch day |
| public static int[] | |
| public static long | Returns: the day number, with day 0 == Jan 1 1970Gregorian year, with 0 == 1 BCE, -1 == 2 BCE, etc. year, int 0-based month, with 0==Jan month, int 1-based day of month dom)Convert a year, month, and day-of-month, given in the proleptic Gregorian calendar, to 1970 epoch days. |
| public static long | |
| private static long | |
| public static int | |
| public static final boolean | Returns: true if the year is a leap yearGregorian year, with 0 == 1 BCE, -1 == 2 BCE, etc. year)Return true if the given year is a leap year. |
| public static final int | Returns: the number of days in the given monthGregorian year, with 0 == 1 BCE, -1 == 2 BCE, etc. year, int 0-based month, with 0==Jan month)Return the number of days in the given month. |
| public static final int | Returns: the number of days in the month previous to the given monthGregorian year, with 0 == 1 BCE, -1 == 2 BCE, etc. year, int 0-based month, with 0==Jan month)Return the length of a previous month of the Gregorian calendar. |
| public static int[] | |
| public static String | Returns: ISO-8601 date stringlong time time)Convenient method for formatting time to ISO 8601 style date string. |
| DAYS_BEFORE | back to summary |
|---|---|
| private static final int[] DAYS_BEFORE | |
| JULIAN_1970_CE | back to summary |
|---|---|
| private static final int JULIAN_1970_CE | |
| JULIAN_1_CE | back to summary |
|---|---|
| private static final int JULIAN_1_CE | |
| MAX_MILLIS | back to summary |
|---|---|
| public static final long MAX_MILLIS | |
| MILLIS_PER_DAY | back to summary |
|---|---|
| public static final int MILLIS_PER_DAY | |
| MILLIS_PER_HOUR | back to summary |
|---|---|
| public static final int MILLIS_PER_HOUR | |
| MILLIS_PER_MINUTE | back to summary |
|---|---|
| public static final int MILLIS_PER_MINUTE | |
| MILLIS_PER_SECOND | back to summary |
|---|---|
| public static final int MILLIS_PER_SECOND | |
| MIN_MILLIS | back to summary |
|---|---|
| public static final long MIN_MILLIS | |
| MONTH_LENGTH | back to summary |
|---|---|
| private static final int[] MONTH_LENGTH | |
| Grego | back to summary |
|---|---|
| public Grego() | |
| dayOfWeek | back to summary |
|---|---|
| public static int dayOfWeek(long day) Return the day of week on the 1970-epoch day
| |
| dayToFields | back to summary |
|---|---|
| public static int[] dayToFields(long day, int[] fields) | |
| fieldsToDay | back to summary |
|---|---|
| public static long fieldsToDay(int year, int month, int dom) Convert a year, month, and day-of-month, given in the proleptic Gregorian calendar, to 1970 epoch days.
| |
| floorDivide | back to summary |
|---|---|
| public static long floorDivide(long numerator, long denominator) | |
| floorDivide | back to summary |
|---|---|
| private static long floorDivide(long numerator, long denominator, long[] remainder) | |
| getDayOfWeekInMonth | back to summary |
|---|---|
| public static int getDayOfWeekInMonth(int year, int month, int dayOfMonth) | |
| isLeapYear | back to summary |
|---|---|
| public static final boolean isLeapYear(int year) Return true if the given year is a leap year.
| |
| monthLength | back to summary |
|---|---|
| public static final int monthLength(int year, int month) Return the number of days in the given month.
| |
| previousMonthLength | back to summary |
|---|---|
| public static final int previousMonthLength(int year, int month) Return the length of a previous month of the Gregorian calendar.
| |
| timeToFields | back to summary |
|---|---|
| public static int[] timeToFields(long time, int[] fields) | |
| timeToString | back to summary |
|---|---|
| public static String timeToString(long time) Convenient method for formatting time to ISO 8601 style date string.
| |