/external/icu/icu4j/main/tests/core/src/com/ibm/icu/dev/test/calendar/ |
JapaneseTest.java | 82 // new JapaneseCalendar(int year, int month, int date) 85 errln("could not create JapaneseCalendar with year,month,date"); 90 // new JapaneseCalendar(int era, int year, int month, int date) 93 errln("could not create JapaneseCalendar with era,year,month,date"); 98 // new JapaneseCalendar(int year, int month, int date, int hour, int minute, int second) 101 errln("could not create JapaneseCalendar with year,month,date,hour,min,second"); 113 logln("min year: " + cal.getMinimum(Calendar.YEAR)); 114 cal.set(Calendar.YEAR, cal.getActualMaximum(Calendar.YEAR)); [all...] |
HebrewTest.java | 45 * The only real nastiness with roll is the MONTH field, since a year can 52 // year month day field amount year month day 72 { 5757, TISHRI, 1, YEAR, 1, 5758, TISHRI, 1 }, 77 { 5758, KISLEV, 30, YEAR, -1, 5757, KISLEV, 29 }, 90 * The only real nastiness with roll is the MONTH field, since a year can 97 // year month day field amount year month day 143 // Julian Day Era Year Month Day WkDay Hour Min Sec 191 // G.YY/MM/DD Era Year Month Day WkDay Hour Min Se [all...] |
/libcore/ojluni/src/test/java/time/test/java/time/chrono/ |
TestIsoChronoImpl.java | 61 import static java.time.temporal.ChronoField.YEAR; 100 cal.set(Calendar.YEAR, isoDate.get(YEAR)); 107 assertEquals(isoDate.get(YEAR_OF_ERA), cal.get(Calendar.YEAR), "Year mismatch in " + isoDate); 131 cal.set(Calendar.YEAR, isoDate.get(YEAR)); 139 assertEquals(isoDate.get(YEAR_OF_ERA), cal.get(Calendar.YEAR), "Year mismatch in " + isoDate);
|
/external/icu/android_icu4j/src/main/java/android/icu/util/ |
SimpleDateRule.java | 123 c.setTime(computeInYear(c.get(Calendar.YEAR), c)); 149 int year = c.get(Calendar.YEAR); local 152 // If the rule is earlier in the year than the start date 153 // we have to go to the next year. 155 year++; 158 // Figure out when the rule lands in the given year 159 Date result = computeInYear(year, c); 162 // to get a result that's before the start. If so, go to next year. 164 result = computeInYear(year+1, c) [all...] |
EasterHoliday.java | 28 * Construct a holiday that falls on Easter Sunday every year 40 * or after Easter Sunday each year. 53 * or after Easter Sunday each year, using either the Western 198 // Figure out when this holiday lands in the given year 203 // We might have gotten a date that's in the same year as "start", but 204 // earlier in the year. If so, go to next year 208 calendar.get(Calendar.YEAR); // JDK 1.1.2 bug workaround 209 calendar.add(Calendar.YEAR, 1); 211 //System.out.println(" Result before start, going to next year: 242 int year = cal.get(Calendar.YEAR); local [all...] |
/external/icu/android_icu4j/src/main/tests/android/icu/dev/test/calendar/ |
HebrewTest.java | 46 * The only real nastiness with roll is the MONTH field, since a year can 53 // year month day field amount year month day 73 { 5757, TISHRI, 1, YEAR, 1, 5758, TISHRI, 1 }, 78 { 5758, KISLEV, 30, YEAR, -1, 5757, KISLEV, 29 }, 91 * The only real nastiness with roll is the MONTH field, since a year can 98 // year month day field amount year month day 144 // Julian Day Era Year Month Day WkDay Hour Min Sec 192 // G.YY/MM/DD Era Year Month Day WkDay Hour Min Se [all...] |
/external/icu/icu4j/main/classes/core/src/com/ibm/icu/util/ |
SimpleDateRule.java | 127 c.setTime(computeInYear(c.get(Calendar.YEAR), c)); 154 int year = c.get(Calendar.YEAR); local 157 // If the rule is earlier in the year than the start date 158 // we have to go to the next year. 160 year++; 163 // Figure out when the rule lands in the given year 164 Date result = computeInYear(year, c); 167 // to get a result that's before the start. If so, go to next year. 169 result = computeInYear(year+1, c) [all...] |
EasterHoliday.java | 27 * Construct a holiday that falls on Easter Sunday every year 40 * or after Easter Sunday each year. 54 * or after Easter Sunday each year, using either the Western 212 // Figure out when this holiday lands in the given year 217 // We might have gotten a date that's in the same year as "start", but 218 // earlier in the year. If so, go to next year 222 calendar.get(Calendar.YEAR); // JDK 1.1.2 bug workaround 223 calendar.add(Calendar.YEAR, 1); 225 //System.out.println(" Result before start, going to next year: 256 int year = cal.get(Calendar.YEAR); local [all...] |
/external/libmtp/ |
hotplug.sh.in | 160 YEAR=`echo ${DATE} | awk 'BEGIN { FS="/"} {print $1; }'` 163 if [ "${YEAR}" -gt "2002" ]; then 166 if [ "${YEAR}" -eq "2002" ]; then
|
/libcore/luni/src/test/java/libcore/icu/ |
DateIntervalFormatTest.java | 31 private static final long YEAR = 12 * MONTH; 46 c.set(Calendar.YEAR, 2009); 83 assertEquals("1/19/2009 ? 2/9/2012", formatDateRange(en_US, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_SHOW_YEAR | FORMAT_NUMERIC_DATE)); 88 assertEquals("19.01.2009 ? 09.02.2012", formatDateRange(de_DE, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_SHOW_YEAR | FORMAT_NUMERIC_DATE)); 93 assertEquals("19/1/2009?9/2/2012", formatDateRange(es_US, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_SHOW_YEAR | FORMAT_NUMERIC_DATE)); 98 assertEquals("19/1/2009?9/2/2012", formatDateRange(es_ES, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_SHOW_YEAR | FORMAT_NUMERIC_DATE)); 112 assertEquals("Jan 19, 2009 ? Feb 9, 2012", formatDateRange(en_US, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_SHOW_DATE | FORMAT_ABBREV_ALL)); 113 assertEquals("Jan 2009 ? Feb 2012", formatDateRange(en_US, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_NO_MONTH_DAY | FORMAT_ABBREV_ALL)); 114 assertEquals("January 19, 2009 ? February 9, 2012", formatDateRange(en_US, tz, fixedTime, fixedTime + 3 * YEAR, 0)); 115 assertEquals("Monday, January 19, 2009 ? Thursday, February 9, 2012", formatDateRange(en_US, tz, fixedTime, fixedTime + 3 * YEAR, FORMAT_SHOW_WEEKDAY)) [all...] |
/libcore/ojluni/src/test/java/time/tck/java/time/chrono/serial/ |
TCKChronoLocalDateSerialization.java | 61 import static java.time.temporal.ChronoField.YEAR; 122 dos.writeInt(date.get(YEAR)); 131 // Test HijrajDate serialization is a type, Chronology, year, month, day 155 dos.writeInt(date.get(YEAR));
|
/libcore/ojluni/src/test/java/time/test/java/time/temporal/ |
TestChronoField.java | 84 fieldMap.put(ChronoField.YEAR, "year"); 110 {ChronoField.YEAR}, 152 ChronoField.YEAR.getDisplayName((Locale)null);
|
/frameworks/base/core/tests/coretests/src/android/text/format/ |
DateFormatTest.java | 45 assertFalse(DateFormat.hasDesignator("hh:mm 'yyyy'", DateFormat.YEAR));
|
/libcore/luni/src/test/java/libcore/java/time/ |
YearMonthTest.java | 21 import java.time.Year; 45 assertEquals(YearMonth.of(1000, Month.JANUARY), ym.with(ChronoField.YEAR, 1000)); 46 assertEquals(YearMonth.of(-1, Month.JANUARY), ym.with(ChronoField.YEAR, -1)); 56 // Proleptic year 0 is 1 BCE. 59 assertEquals(YearMonth.of(Year.MAX_VALUE, Month.DECEMBER), ym.with(ChronoField.PROLEPTIC_MONTH, Year.MAX_VALUE * 12L + 11)); 60 assertEquals(YearMonth.of(Year.MIN_VALUE, Month.JANUARY), ym.with(ChronoField.PROLEPTIC_MONTH, Year.MIN_VALUE * 12L)); 67 { ChronoField.YEAR_OF_ERA, Year.MAX_VALUE + 1 }, 68 { ChronoField.YEAR, Year.MIN_VALUE - 1 } [all...] |
/libcore/luni/src/test/java/libcore/java/util/ |
DateTest.java | 51 c.set(Calendar.YEAR, 21); 54 c.set(Calendar.YEAR, 321); 65 c.set(Calendar.YEAR, 21); 68 c.set(Calendar.YEAR, 321);
|
CalendarBuilderTest.java | 156 builder.set(Calendar.YEAR, 2000); 159 expected.set(Calendar.YEAR, 2000); 178 builder.set(Calendar.YEAR, 2000); 186 builder.setFields(Calendar.YEAR, 2000, Calendar.MONTH, Calendar.FEBRUARY); 189 expected.set(Calendar.YEAR, 2000); 212 new Calendar.Builder().setFields(Calendar.YEAR); 220 builder.setFields(Calendar.YEAR, 2000); 238 builder.set(Calendar.YEAR, 2000);
|
/libcore/ojluni/src/main/java/java/time/chrono/ |
MinguoChronology.java | 61 import static java.time.temporal.ChronoField.YEAR; 90 * <li>year-of-era - The year-of-era for the current era increases uniformly from the epoch at year one. 91 * For the previous era the year increases from one as time goes backwards. 92 * The value for the current era is equal to the ISO proleptic-year minus 1911. 93 * <li>proleptic-year - The proleptic year is the same as the year-of-era for the 95 * The value is equal to the ISO proleptic-year minus 1911 [all...] |
/cts/tests/tests/widget/src/android/widget/cts/ |
DatePickerTest.java | 191 // Use a range of minus/plus one year as min/max dates 193 minCalendar.set(Calendar.YEAR, minCalendar.get(Calendar.YEAR) - 1); 195 maxCalendar.set(Calendar.YEAR, maxCalendar.get(Calendar.YEAR) + 1); 236 calendar.set(Calendar.YEAR, 2008); 240 calendar.get(Calendar.YEAR), 248 assertEquals(calendar.get(Calendar.YEAR), calendarFromSpinner.get(Calendar.YEAR));
|
/frameworks/support/v17/leanback/src/android/support/v17/leanback/widget/picker/ |
DatePicker.java | 38 * year, month, and day Columns. The "minDate" and "maxDate" from which dates to be selected 206 mTempDate.add(Calendar.YEAR, newVal - oldVal); 210 setDate(mTempDate.get(Calendar.YEAR), mTempDate.get(Calendar.MONTH), 225 if (mTempDate.get(Calendar.YEAR) == mMinDate.get(Calendar.YEAR) 260 if (mTempDate.get(Calendar.YEAR) == mMaxDate.get(Calendar.YEAR) 295 private void setDate(int year, int month, int dayOfMonth) { 296 mCurrentDate.set(year, month, dayOfMonth); 307 * @param year The year [all...] |
/libcore/ojluni/src/test/java/time/test/java/time/format/ |
TestStringLiteralParser.java | 62 import static java.time.temporal.ChronoField.YEAR; 116 assertEquals(parsed.isSupported(YEAR), false);
|
/packages/apps/Contacts/src/com/android/contacts/interactions/ |
ContactInteractionUtil.java | 77 * Compares the day and year of two calendars. 80 return c1.get(Calendar.YEAR) == c2.get(Calendar.YEAR) &&
|
/cts/tests/tests/provider/src/android/provider/cts/ |
MediaStoreAudioTestHelper.java | 89 public static final int YEAR = 1992; 134 values.put(Media.YEAR, YEAR); 165 public static final int YEAR = 1992; 213 values.put(Media.YEAR, YEAR);
|
/packages/apps/Contacts/src/com/android/contacts/util/ |
DateUtils.java | 37 * When parsing a date without a year, the system assumes 1970, which wasn't a leap-year. 38 * Let's add a one-off hack for that day of the year 66 * @param mustContainYear If true, the string is parsed as a date containing a year. If false, 67 * the string is parsed into a valid date even if the year field is missing. 107 calendar.set(Calendar.YEAR, 0); 112 private static final Calendar getUtcDate(int year, int month, int dayOfMonth) { 115 calendar.set(Calendar.YEAR, year); 122 // use the Calendar.YEAR field to track whether or not the year is set instead o [all...] |
/packages/apps/Dialer/java/com/android/contacts/common/util/ |
DateUtils.java | 36 * When parsing a date without a year, the system assumes 1970, which wasn't a leap-year. Let's 37 * add a one-off hack for that day of the year 65 * @param mustContainYear If true, the string is parsed as a date containing a year. If false, the 66 * string is parsed into a valid date even if the year field is missing. 106 calendar.set(Calendar.YEAR, 0); 111 private static final Calendar getUtcDate(int year, int month, int dayOfMonth) { 114 calendar.set(Calendar.YEAR, year); 121 // use the Calendar.YEAR field to track whether or not the year is set instead o [all...] |
/libcore/ojluni/src/test/java/time/tck/java/time/format/ |
TCKDateTimeFormatterBuilder.java | 67 import static java.time.temporal.ChronoField.YEAR; 112 .parseDefaulting(YEAR, 2012).parseDefaulting(MONTH_OF_YEAR, 6) 121 .appendValue(YEAR) 203 builder.appendValueReduced(YEAR, 0, 2, 2000); 208 builder.appendValueReduced(YEAR, 11, 2, 2000); 213 builder.appendValueReduced(YEAR, 2, 0, 2000); 218 builder.appendValueReduced(YEAR, 2, 11, 2000); 223 builder.appendValueReduced(YEAR, 2, 1, 2000); 234 builder.appendValueReduced(YEAR, 2, 2, null); 239 builder.appendValueReduced(YEAR, 0, 2, LocalDate.of(2000, 1, 1)) [all...] |