/libcore/ojluni/src/test/java/time/tck/java/time/chrono/ |
D | TCKJapaneseEra.java | 59 import static java.time.temporal.ChronoField.ERA; 117 assertEquals(era.range(ERA).getMinimum(), -1); in test_range() 118 assertEquals(era.range(ERA).getLargestMinimum(), -1); in test_range() 119 assertEquals(era.range(ERA).getSmallestMaximum(), era.range(ERA).getMaximum()); in test_range() 120 assertEquals(era.range(ERA).getMaximum() >= 2, true); in test_range()
|
D | TCKThaiBuddhistEra.java | 59 import static java.time.temporal.ChronoField.ERA; 116 assertEquals(era.range(ERA), ValueRange.of(0, 1)); in test_range()
|
D | TCKIsoEra.java | 59 import static java.time.temporal.ChronoField.ERA; 112 assertEquals(era.range(ERA), ValueRange.of(0, 1)); in test_range()
|
D | TCKMinguoEra.java | 60 import static java.time.temporal.ChronoField.ERA; 117 assertEquals(era.range(ERA), ValueRange.of(0, 1)); in test_range()
|
D | TCKHijrahEra.java | 59 import static java.time.temporal.ChronoField.ERA; 113 assertEquals(era.range(ERA), ValueRange.of(1, 1)); in test_range()
|
/libcore/ojluni/src/main/java/java/time/chrono/ |
D | Era.java | 64 import static java.time.temporal.ChronoField.ERA; 147 return field == ERA; in isSupported() 209 if (field == ERA) { in get() 239 if (field == ERA) { in getLong() 301 return temporal.with(ERA, getValue()); in adjustInto() 321 … return new DateTimeFormatterBuilder().appendText(ERA, style).toFormatter(locale).format(this); in getDisplayName()
|
D | HijrahEra.java | 64 import static java.time.temporal.ChronoField.ERA; 152 if (field == ERA) { in range()
|
D | ChronoLocalDateImpl.java | 60 import static java.time.temporal.ChronoField.ERA; 209 case ERAS: return with(ERA, Math.addExact(getLong(ERA), amountToAdd)); in plus() 388 case ERAS: return end.getLong(ERA) - getLong(ERA); in until()
|
D | JapaneseChronology.java | 61 import static java.time.temporal.ChronoField.ERA; 424 case ERA: in range() 440 Long eraLong = fieldValues.get(ERA); in resolveYearOfEra() 443 era = eraOf(range(ERA).checkValidIntValue(eraLong, ERA)); // always validated in resolveYearOfEra() 473 fieldValues.remove(ERA); in resolveYMD() 506 fieldValues.remove(ERA); in resolveYD()
|
D | IsoChronology.java | 66 import static java.time.temporal.ChronoField.ERA; 514 Long era = fieldValues.remove(ERA); in resolveYearOfEra() 536 } else if (fieldValues.containsKey(ERA)) { in resolveYearOfEra() 537 ERA.checkValidValue(fieldValues.get(ERA)); // always validated in resolveYearOfEra()
|
D | JapaneseEra.java | 65 import static java.time.temporal.ChronoField.ERA; 297 .appendText(ERA, style) in getDisplayName() 396 if (field == ERA) { in range() 397 return JapaneseChronology.INSTANCE.range(ERA); in range()
|
D | JapaneseDate.java | 393 jcal.set(Calendar.ERA, era.getValue() + JapaneseEra.ERA_OFFSET); in lengthOfYear() 453 jcal.set(Calendar.ERA, era.getValue() + JapaneseEra.ERA_OFFSET); in range() 481 case ERA: in getLong() 486 jcal.set(Calendar.ERA, era.getValue() + JapaneseEra.ERA_OFFSET); in getLong() 524 case ERA: { in with() 531 case ERA: { in with()
|
D | AbstractChronology.java | 72 import static java.time.temporal.ChronoField.ERA; 516 Long eraLong = fieldValues.remove(ERA); in resolveYearOfEra() 524 Era eraObj = eraOf(range(ERA).checkValidIntValue(eraLong, ERA)); in resolveYearOfEra() 545 } else if (fieldValues.containsKey(ERA)) { in resolveYearOfEra() 546 range(ERA).checkValidValue(fieldValues.get(ERA), ERA); // always validated in resolveYearOfEra() local
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/text/ |
D | DataFormatFieldTest.java | 37 MyField field = new MyField("day of month", Calendar.ERA); in test_ConstructorLjava_lang_StringLjava_lang_String() 40 assertEquals("field has wrong Calendar field number", Calendar.ERA, in test_ConstructorLjava_lang_StringLjava_lang_String() 44 .ofCalendarField(Calendar.ERA); in test_ConstructorLjava_lang_StringLjava_lang_String() 46 DateFormat.Field.ERA, realField); in test_ConstructorLjava_lang_StringLjava_lang_String() 86 MyField field = new MyField("day of month", Calendar.ERA); in test_Constructor2() 89 assertEquals("field has wrong Calendar field number", Calendar.ERA, in test_Constructor2() 93 .ofCalendarField(Calendar.ERA); in test_Constructor2() 95 DateFormat.Field.ERA, realField); in test_Constructor2()
|
D | FieldPositionTest.java | 99 FieldPosition fpos3 = new FieldPosition(DateFormat.Field.ERA, 1); in test_equalsLjava_lang_Object() 227 FieldPosition fpos2 = new FieldPosition(DateFormat.Field.ERA); in test_toString() 231 "java.text.FieldPosition[field=-1,attribute=" + DateFormat.Field.ERA in test_toString()
|
/libcore/ojluni/src/test/java/time/test/java/time/format/ |
D | TestTextPrinter.java | 64 import static java.time.temporal.ChronoField.ERA; 185 {ERA, TextStyle.FULL, 0, "Before Christ"}, in provider_dow() 186 {ERA, TextStyle.FULL, 1, "Anno Domini"}, in provider_dow() 187 {ERA, TextStyle.SHORT, 0, "BC"}, in provider_dow() 188 {ERA, TextStyle.SHORT, 1, "AD"}, in provider_dow() 189 {ERA, TextStyle.NARROW, 0, "B"}, in provider_dow() 190 {ERA, TextStyle.NARROW, 1, "A"}, in provider_dow() 226 …{ERA, TextStyle.FULL, 2, "Heisei"}, // Note: CLDR doesn't define "wide" Japanese era nam… in provider_japaneseEra() 227 {ERA, TextStyle.SHORT, 2, "Heisei"}, in provider_japaneseEra() 228 {ERA, TextStyle.NARROW, 2, "H"}, in provider_japaneseEra()
|
/libcore/luni/src/test/java/libcore/java/time/ |
D | YearMonthTest.java | 50 assertSame(ym, ym.with(ChronoField.ERA, IsoEra.CE.getValue())); in test_with_TemporalField_long() 51 assertSame(bceYm, bceYm.with(ChronoField.ERA, IsoEra.BCE.getValue())); in test_with_TemporalField_long() 53 assertEquals(bceYm, ym.with(ChronoField.ERA, IsoEra.BCE.getValue())); in test_with_TemporalField_long() 54 assertEquals(ym, bceYm.with(ChronoField.ERA, IsoEra.CE.getValue())); in test_with_TemporalField_long() 70 { ChronoField.ERA, -1 }, in test_with_TemporalField_long_invalidValue() 71 { ChronoField.ERA, 2 }, in test_with_TemporalField_long_invalidValue()
|
/libcore/ojluni/src/main/java/java/time/ |
D | Year.java | 64 import static java.time.temporal.ChronoField.ERA; 364 return field == YEAR || field == YEAR_OF_ERA || field == ERA; in isSupported() 495 case ERA: return (year < 1 ? 0 : 1); in getLong() 620 case ERA: return (getLong(ERA) == newValue ? this : Year.of(1 - year)); in with() 709 case ERAS: return with(ERA, Math.addExact(getLong(ERA), amountToAdd)); in plus() 916 case ERAS: return end.getLong(ERA) - getLong(ERA); in until()
|
D | YearMonth.java | 64 import static java.time.temporal.ChronoField.ERA; 351 field == PROLEPTIC_MONTH || field == YEAR_OF_ERA || field == ERA; in isSupported() 486 case ERA: return (year < 1 ? 0 : 1); in getLong() 685 case ERA: return (getLong(ERA) == newValue ? this : withYear(1 - year)); in with() 807 case ERAS: return with(ERA, Math.addExact(getLong(ERA), amountToAdd)); in plus() 1049 case ERAS: return end.getLong(ERA) - getLong(ERA); in until()
|
/libcore/ojluni/src/main/java/java/time/format/ |
D | DateTimeTextProvider.java | 70 import static java.time.temporal.ChronoField.ERA; 173 if (field == ERA) { in getText() 174 fieldIndex = Calendar.ERA; in getText() 253 case ERA: in getTextIterator() 254 fieldIndex = Calendar.ERA; in getTextIterator() 277 case Calendar.ERA: in getTextIterator() 330 if (field == ERA) { in createStore() 337 "gregory", Calendar.ERA, textStyle.toCalendarStyle(), locale); in createStore()
|
/libcore/ojluni/src/main/java/java/time/temporal/ |
D | ChronoField.java | 561 ERA("Era", ERAS, FOREVER, ValueRange.of(0, 1), "era"), enumConstant 650 case ERA: in getIcuFieldNumber() 651 return DateTimePatternGenerator.ERA; in getIcuFieldNumber() 699 return ordinal() >= DAY_OF_WEEK.ordinal() && ordinal() <= ERA.ordinal(); in isDateBased()
|
/libcore/ojluni/src/main/java/sun/util/locale/provider/ |
D | CalendarDataUtility.java | 105 if (field == Calendar.ERA) { in retrieveFieldValueName() 230 if (field == Calendar.ERA) { in retrieveFieldValueNamesImpl() 268 case Calendar.ERA: in getNames()
|
/libcore/ojluni/src/test/java/time/tck/java/time/temporal/serial/ |
D | TCKChronoFieldSerialization.java | 86 import static java.time.temporal.ChronoField.ERA; 120 {ERA}, in data_fieldBased()
|
/libcore/ojluni/src/test/java/time/test/java/time/temporal/ |
D | TestChronoField.java | 83 fieldMap.put(ChronoField.ERA, "era"); in initClass() 109 {ChronoField.ERA}, in data_localeDisplayNames()
|
/libcore/ojluni/src/main/java/java/util/ |
D | GregorianCalendar.java | 942 set(ERA, BCE); 952 set(ERA, CE); 974 set(ERA, BCE); 984 set(ERA, CE); 1000 } else if (field == ERA) { 1001 int era = internalGet(ERA) + amount; 1008 set(ERA, era); 1187 case ERA: in roll() 1480 set(ERA, (d.getNormalizedYear() <= 0 ? BCE : CE)); in roll() 2216 int era = gc.get(ERA); in setWeekDate() [all …]
|