/libcore/luni/src/main/java/java/util/ |
H A D | Grego.java | 56 * Return true if the given year is a leap year.
57 * @param year Gregorian year, with 0 == 1 BCE, -1 == 2 BCE, etc.
58 * @return true if the year is a leap year
60 public static final boolean isLeapYear(int year) {
argument 61 // year&0x3 == year%4
62 return ((year 71 monthLength(int year, int month) argument 81 previousMonthLength(int year, int month) argument 93 fieldsToDay(int year, int month, int dom) argument 203 getDayOfWeekInMonth(int year, int month, int dayOfMonth) argument [all...] |
H A D | GregorianCalendar.java | 42 * the Julian calendar is the leap year rule. The Julian calendar specifies leap 54 * date, leap year rules were applied irregularly, and before 45 BC the Julian 65 * 53. Week 1 for a year is the earliest seven day period starting on 67 * {@code getMinimalDaysInFirstWeek()} days from that year. It thus 70 * Weeks between week 1 of one year and week 1 of the following year are 89 * {@code getFirstDayOfWeek()}. Unlike week 1 of a year, week 1 of a 238 * @param year 239 * the year. 245 public GregorianCalendar(int year, in argument 265 GregorianCalendar(int year, int month, int day, int hour, int minute) argument 287 GregorianCalendar(int year, int month, int day, int hour, int minute, int second) argument 808 daysFromBaseYear(long year) argument 842 daysInYear(int year) argument 1067 isLeapYear(int year) argument [all...] |
H A D | Date.java | 58 * @param year 59 * the year, 0 is 1900. 69 public Date(int year, int month, int day) { argument 71 cal.set(1900 + year, month, day); 79 * @param year 80 * the year, 0 is 1900. 94 public Date(int year, int month, int day, int hour, int minute) { argument 96 cal.set(1900 + year, month, day, hour, minute); 104 * @param year 105 * the year, 121 Date(int year, int month, int day, int hour, int minute, int second) argument 650 setYear(int year) argument 747 UTC(int year, int month, int day, int hour, int minute, int second) argument [all...] |
H A D | SimpleTimeZone.java | 342 public int getOffset(int era, int year, int month, int day, int dayOfWeek, int time) { argument 347 if (month != Calendar.FEBRUARY || day != 29 || !isLeapYear(year)) { 351 if (!useDaylightTime() || era != GregorianCalendar.AD || year < startYear) { 377 year)) { 419 if (endMonth == Calendar.FEBRUARY && isLeapYear(year)) { 454 if (ruleMonth == Calendar.FEBRUARY && isLeapYear(year)) { 530 private boolean isLeapYear(int year) { argument 531 if (year > 1582) { 532 return year % 4 == 0 && (year 788 setStartYear(int year) argument [all...] |
H A D | Calendar.java | 57 * fields, as well as their meaning. For example, the first month of the year 84 * the first week of the month or year as a reference point. The first week of a 85 * month or year is defined as the earliest seven day period beginning on 87 * {@code getMinimalDaysInFirstWeek()} days of that month or year. Weeks 91 * designate the week before week 1 of a year as week <em>n</em> of the 92 * previous year. 97 * {@code Date} (such as only year and month but no day in the month), or 220 * gives September of the next year. Since {@code DAY_OF_MONTH} cannot be 265 * increment and decrement buttons for the month, day, and year, and an 348 * year 1231 set(int year, int month, int day) argument 1252 set(int year, int month, int day, int hourOfDay, int minute) argument 1276 set(int year, int month, int day, int hourOfDay, int minute, int second) argument [all...] |
H A D | TimeZone.java | 275 public abstract int getOffset(int era, int year, int month, int day, argument 426 * savings before but plans to start next year would return true.
|
/libcore/luni/src/main/java/libcore/util/ |
H A D | ZoneInfo.java | 137 public int getOffset(int era, int year, int month, int day, int dayOfWeek, int millis) { argument 142 long calc = (year / 400) * MILLISECONDS_PER_400_YEARS; 143 year %= 400; 145 calc += year * (365 * MILLISECONDS_PER_DAY); 146 calc += ((year + 3) / 4) * MILLISECONDS_PER_DAY; 148 if (year > 0) { 149 calc -= ((year - 1) / 100) * MILLISECONDS_PER_DAY; 152 boolean isLeap = (year == 0 || (year % 4 == 0 && year [all...] |
/libcore/luni/src/main/java/javax/xml/datatype/ |
H A D | DatatypeFactory.java | 145 * Gregorian year, month, day, hour, minute, and second components defined in Section 5.5.3.2 of [ISO 8601], respectively. 147 * year, month, day, hour, minute, and second. 174 * Gregorian year, month, day, hour, minute, and second components defined in Section 5.5.3.2 of [ISO 8601], respectively. 176 * year, month, day, hour, minute, and second. 522 * whose lexical representation contains only year and month components. 561 * whose lexical representation contains only year and month components. 583 * <p>Any remaining milliseconds after determining the year and month are discarded.</p> 596 * <code>year</code> and <code>month</code> as defined in 609 * @param year Year of <code>Duration</code>. 612 * @return New <code>Duration</code> created using the specified <code>year</cod 617 newDurationYearMonth( final boolean isPositive, final BigInteger year, final BigInteger month) argument 650 newDurationYearMonth( final boolean isPositive, final int year, final int month) argument 785 newXMLGregorianCalendar( final BigInteger year, final int month, final int day, final int hour, final int minute, final int second, final BigDecimal fractionalSecond, final int timezone) argument 821 newXMLGregorianCalendar( final int year, final int month, final int day, final int hour, final int minute, final int second, final int millisecond, final int timezone) argument 883 newXMLGregorianCalendarDate( final int year, final int month, final int day, final int timezone) argument [all...] |
H A D | XMLGregorianCalendar.java | 66 * <a name="datetimefield-year"/> 68 * <td> year </td> 74 * {@link #getEon()} is high order year value in billion of years.<br/> 77 * Given that <a href="http://www.w3.org/2001/05/xmlschema-errata#e2-63">XML Schema 1.0 errata</a> states that the year zero 79 * this class allows the year field to be set to zero. Otherwise, 80 * the year field value is handled exactly as described 82 * validation does not allow for the year field to have a value of zero. 196 * BigInteger year, 205 * int year, 215 * int year, 254 setYear(BigInteger year) argument 269 setYear(int year) argument [all...] |
/libcore/luni/src/main/java/java/sql/ |
H A D | Date.java | 24 * format only deals with year, month and day values. There are no values for 41 * Constructs a {@code Date} object corresponding to the supplied year, 46 * the year, specified as the year minus 1900. Must be in the 229 int year = Integer.parseInt(dateString.substring(0, firstIndex)); 234 return new Date(year - 1900, month - 1, day);
|
/libcore/luni/src/test/java/libcore/java/util/ |
H A D | CalendarTest.java | 146 private void testSetSelfConsistent(TimeZone timeZone, int year, int month, int day) { argument 151 calendar.set(year, month, day, hour, minute); 152 assertEquals(year, calendar.get(Calendar.YEAR)); 196 int year, int month, int day, int hour, int minute) { 197 assertEquals(year, calendar.get(Calendar.YEAR)); 195 assertCalendarEquals(Calendar calendar, int year, int month, int day, int hour, int minute) argument
|
H A D | OldTimeZoneTest.java | 31 public int getOffset(int era, int year, int month, int day, int dayOfWeek, int milliseconds) { argument
|
/libcore/luni/src/main/java/java/text/ |
H A D | SimpleDateFormat.java | 63 * <tr> <td>{@code D}</td> <td>day in year</td> <td>(Number)</td> <td>189</td> </tr> 70 * <tr> <td>{@code M}</td> <td>month in year</td> <td>(Text/Number)</td> <td>July / 07</td> </tr> 81 * <tr> <td>{@code w}</td> <td>week in year</td> <td>(Number)</td> <td>27</td> </tr> 82 * <tr> <td>{@code y}</td> <td>year</td> <td>(Number)</td> <td>2010</td> </tr> 432 * properties, pattern, {@code DateFormatSymbols} and creation year. 598 int year = calendar.get(Calendar.YEAR); 605 appendNumber(buffer, 2, year % 100); 607 appendNumber(buffer, count, year); 822 * Returns the date which is the start of the one hundred year period for two-digit year value [all...] |
/libcore/luni/src/main/java/java/util/zip/ |
H A D | ZipEntry.java | 277 int year = cal.get(Calendar.YEAR); 278 if (year < 1980) {
|
/libcore/luni/src/test/java/tests/api/java/util/ |
H A D | CalendarTest.java | 467 int year = Integer.MIN_VALUE + 71; 469 cal.set(Calendar.YEAR, year + 1900); 552 // test by year
|