Home
last modified time | relevance | path

Searched refs:Chronology (Results 1 – 25 of 70) sorted by relevance

123

/libcore/ojluni/src/test/java/time/tck/java/time/chrono/
DTCKChronology.java79 import java.time.chrono.Chronology;
129 Chronology chrono = Chronology.of(chronoId); in test_getters()
137 Chronology chrono = Chronology.of(chronoId); in test_required_calendars()
139 chrono = Chronology.of(calendarSystemType); in test_required_calendars()
141 Set<Chronology> cals = Chronology.getAvailableChronologies(); in test_required_calendars()
147 Set<Chronology> chronos = Chronology.getAvailableChronologies(); in test_calendar_list()
149 for (Chronology chrono : chronos) { in test_calendar_list()
150 Chronology lookup = Chronology.of(chrono.getId()); in test_calendar_list()
175 Chronology chrono = Chronology.of(chronoId); in test_getDisplayName()
184Chronology chrono = Chronology.of(name); // a chronology. In practice this is rarely hardcoded in test_epoch()
[all …]
DTCKChronoPeriod.java74 import java.time.chrono.Chronology;
93 Chronology[][] data_of_calendars() { in data_of_calendars()
94 return new Chronology[][]{ in data_of_calendars()
106 public void test_serialization(Chronology chrono) throws Exception { in test_serialization()
120 public void test_get(Chronology chrono) { in test_get()
128 public void test_get_unsupported(Chronology chrono) { in test_get_unsupported()
134 public void test_getUnits(Chronology chrono) { in test_getUnits()
143 public void test_getChronology(Chronology chrono) { in test_getChronology()
149 public void test_isZero_isNegative(Chronology chrono) { in test_isZero_isNegative()
165 public void test_plus(Chronology chrono) { in test_plus()
[all …]
DTCKChronoLocalDate.java72 import java.time.chrono.Chronology;
104 Chronology[][] data_of_calendars() { in data_of_calendars()
105 return new Chronology[][]{ in data_of_calendars()
114 public void test_badWithAdjusterChrono(Chronology chrono) { in test_badWithAdjusterChrono()
117 for (Chronology[] clist : data_of_calendars()) { in test_badWithAdjusterChrono()
118 Chronology chrono2 = clist[0]; in test_badWithAdjusterChrono()
137 public void test_badPlusAdjusterChrono(Chronology chrono) { in test_badPlusAdjusterChrono()
140 for (Chronology[] clist : data_of_calendars()) { in test_badPlusAdjusterChrono()
141 Chronology chrono2 = clist[0]; in test_badPlusAdjusterChrono()
160 public void test_badMinusAdjusterChrono(Chronology chrono) { in test_badMinusAdjusterChrono()
[all …]
DTCKChronoLocalDateTime.java73 import java.time.chrono.Chronology;
104 Chronology[][] data_of_calendars() { in data_of_calendars()
105 return new Chronology[][]{ in data_of_calendars()
114 public void test_badWithAdjusterChrono(Chronology chrono) { in test_badWithAdjusterChrono()
117 for (Chronology[] clist : data_of_calendars()) { in test_badWithAdjusterChrono()
118 Chronology chrono2 = clist[0]; in test_badWithAdjusterChrono()
138 public void test_badPlusAdjusterChrono(Chronology chrono) { in test_badPlusAdjusterChrono()
141 for (Chronology[] clist : data_of_calendars()) { in test_badPlusAdjusterChrono()
142 Chronology chrono2 = clist[0]; in test_badPlusAdjusterChrono()
162 public void test_badMinusAdjusterChrono(Chronology chrono) { in test_badMinusAdjusterChrono()
[all …]
DTCKChronoZonedDateTime.java74 import java.time.chrono.Chronology;
105 Chronology[][] data_of_calendars() { in data_of_calendars()
106 return new Chronology[][]{ in data_of_calendars()
116 public void test_badWithAdjusterChrono(Chronology chrono) { in test_badWithAdjusterChrono()
119 for (Chronology[] clist : data_of_calendars()) { in test_badWithAdjusterChrono()
120 Chronology chrono2 = clist[0]; in test_badWithAdjusterChrono()
139 public void test_badPlusAdjusterChrono(Chronology chrono) { in test_badPlusAdjusterChrono()
142 for (Chronology[] clist : data_of_calendars()) { in test_badPlusAdjusterChrono()
143 Chronology chrono2 = clist[0]; in test_badPlusAdjusterChrono()
163 public void test_badMinusAdjusterChrono(Chronology chrono) { in test_badMinusAdjusterChrono()
[all …]
DTCKTestServiceLoader.java65 import java.time.chrono.Chronology;
78 Chronology chrono = Chronology.of("Coptic"); in test_TestServiceLoader()
/libcore/ojluni/src/test/java/time/test/java/time/chrono/
DTestServiceLoader.java63 import java.time.chrono.Chronology;
79 Map<String, Chronology> chronos = new HashMap<>(); in test_copticServiceLoader()
82 ServiceLoader<Chronology> loader = ServiceLoader.load(Chronology.class, in test_copticServiceLoader()
84 for (Chronology chrono : loader) { in test_copticServiceLoader()
DTestExampleCode.java68 import java.time.chrono.Chronology;
89 ChronoLocalDate now1 = Chronology.of("ThaiBuddhist").dateNow(); in test_chronoPackageExample()
98 Set<Chronology> chronos = Chronology.getAvailableChronologies(); in test_chronoPackageExample()
99 for (Chronology chrono : chronos) { in test_chronoPackageExample()
131 Chronology chrono = Chronology.ofLocale(locale); in test_HijrahTypeViaLocale()
134 Chronology expected = Chronology.of(calendarId); in test_HijrahTypeViaLocale()
142 Set<Chronology> chronos = Chronology.getAvailableChronologies(); in test_calendarPackageExample()
143 for (Chronology chrono : chronos) { in test_calendarPackageExample()
DTestChronologyPerf.java28 import java.time.chrono.Chronology;
44 Set<Chronology> chronos = Chronology.getAvailableChronologies(); in test_chronologyGetAvailablePerf()
50 chronos = Chronology.getAvailableChronologies(); in test_chronologyGetAvailablePerf()
/libcore/ojluni/src/main/java/java/time/chrono/
DAbstractChronology.java127 public abstract class AbstractChronology implements Chronology {
132 …private static final ConcurrentHashMap<String, Chronology> CHRONOS_BY_ID = new ConcurrentHashMap<>…
136 …private static final ConcurrentHashMap<String, Chronology> CHRONOS_BY_TYPE = new ConcurrentHashMap…
146 static Chronology registerChrono(Chronology chrono) { in registerChrono()
159 static Chronology registerChrono(Chronology chrono, String id) { in registerChrono()
160 Chronology prev = CHRONOS_BY_ID.putIfAbsent(id, chrono); in registerChrono()
224 static Chronology ofLocale(Locale locale) { in ofLocale()
232 Chronology chrono = CHRONOS_BY_TYPE.get(type); in ofLocale()
242 ServiceLoader<Chronology> loader = ServiceLoader.load(Chronology.class); in ofLocale()
243 for (Chronology chrono : loader) { in ofLocale()
[all …]
DChronology.java163 public interface Chronology extends Comparable<Chronology> { interface
182 static Chronology from(TemporalAccessor temporal) { in from()
184 Chronology obj = temporal.query(TemporalQueries.chronology()); in from()
229 static Chronology ofLocale(Locale locale) { in ofLocale()
254 static Chronology of(String id) { in of()
268 static Set<Chronology> getAvailableChronologies() { in getAvailableChronologies()
659 return (R) Chronology.this; in getDisplayName()
785 int compareTo(Chronology other); in compareTo()
/libcore/ojluni/src/test/java/time/test/java/time/format/
DTestNonIsoFormatter.java37 import java.time.chrono.Chronology;
66 private static final Chronology ISO8601 = IsoChronology.INSTANCE;
67 private static final Chronology JAPANESE = JapaneseChronology.INSTANCE;
68 private static final Chronology HIJRAH = HijrahChronology.INSTANCE;
69 private static final Chronology MINGUO = MinguoChronology.INSTANCE;
70 private static final Chronology BUDDHIST = ThaiBuddhistChronology.INSTANCE;
154 …public void test_formatLocalizedDate(Chronology chrono, Locale formatLocale, Locale numberingLocal… in test_formatLocalizedDate()
164 …public void test_parseLocalizedText(Chronology chrono, Locale formatLocale, Locale numberingLocale, in test_parseLocalizedText()
182 public void test_chronoNames(Chronology chrono, Locale locale, String expected) { in test_chronoNames()
188 Chronology cal = ta.query(TemporalQueries.chronology()); in test_chronoNames()
[all …]
DTestUnicodeExtension.java38 import java.time.chrono.Chronology;
63 private static final Chronology JAPANESE = JapaneseChronology.INSTANCE;
64 private static final Chronology HIJRAH = HijrahChronology.INSTANCE;
769 public void test_localizedBy(Locale locale, Chronology chrono, ZoneId zone, in test_localizedBy()
770 Chronology chronoExpected, ZoneId zoneExpected, in test_localizedBy()
784 public void test_withLocale(Locale locale, Chronology chrono, ZoneId zone, in test_withLocale()
785 Chronology chronoExpected, ZoneId zoneExpected, in test_withLocale()
812 Chronology chronoExpected, ZoneId zoneExpected, in test_ofPattern()
826 Chronology chronoExpected, ZoneId zoneExpected, in test_toFormatter()
/libcore/luni/src/test/java/libcore/java/time/chrono/
DChronologyTest.java21 import java.time.chrono.Chronology;
42 Set<Chronology> chronologies = new LinkedHashSet<>(Chronology.getAvailableChronologies()); in test_compareTo()
47 for (Chronology c1 : chronologies) { in test_compareTo()
48 for (Chronology c2 : chronologies) { in test_compareTo()
54 private static void assertComparesAccordingToId(Chronology c1, Chronology c2) { in assertComparesAccordingToId()
DChronologyDisplayNameTest.java21 import java.time.chrono.Chronology;
42 public static List<Chronology> getChronologies() { in getChronologies()
43 return new ArrayList<>(Chronology.getAvailableChronologies()); in getChronologies()
46 private final Chronology chronology;
48 public ChronologyDisplayNameTest(Chronology chronology) { in ChronologyDisplayNameTest()
/libcore/ojluni/src/main/java/java/time/format/
DDateTimeParseContext.java65 import java.time.chrono.Chronology;
113 private ArrayList<Consumer<Chronology>> chronoListeners = null;
166 Chronology getEffectiveChronology() { in getEffectiveChronology()
167 Chronology chrono = currentParsed().chrono; in getEffectiveChronology()
381 void setParsed(Chronology chrono) { in setParsed()
386 Consumer<Chronology>[] tmp = new Consumer[1]; in setParsed()
387 Consumer<Chronology>[] listeners = chronoListeners.toArray(tmp); in setParsed()
389 for (Consumer<Chronology> l : listeners) { in setParsed()
400 void addChronoChangedListener(Consumer<Chronology> listener) { in addChronoChangedListener()
DDateTimePrintContext.java73 import java.time.chrono.Chronology;
125 Chronology overrideChrono = formatter.getChronology(); in adjust()
132 Chronology temporalChrono = temporal.query(TemporalQueries.chronology()); in adjust()
145 … final Chronology effectiveChrono = (overrideChrono != null ? overrideChrono : temporalChrono); in adjust()
149Chronology chrono = Objects.requireNonNullElse(effectiveChrono, IsoChronology.INSTANCE); in adjust()
/libcore/ojluni/src/test/java/time/tck/java/time/chrono/serial/
DTCKChronologySerialization.java62 import java.time.chrono.Chronology;
83 Chronology[][] data_of_calendars() { in data_of_calendars()
84 return new Chronology[][]{ in data_of_calendars()
96 public void test_chronoSerialization(Chronology chrono) throws Exception { in test_chronoSerialization()
104 private void test_serializationBytes(Chronology chrono) throws Exception { in test_serializationBytes()
DTCKChronoLocalDateTimeSerialization.java65 import java.time.chrono.Chronology;
84 Chronology[][] data_of_calendars() { in data_of_calendars()
85 return new Chronology[][]{ in data_of_calendars()
97 public void test_ChronoLocalDateTimeSerialization(Chronology chrono) throws Exception { in test_ChronoLocalDateTimeSerialization()
DTCKChronoZonedDateTimeSerialization.java63 import java.time.chrono.Chronology;
83 Chronology[][] data_of_calendars() { in data_of_calendars()
84 return new Chronology[][]{ in data_of_calendars()
97 public void test_ChronoZonedDateTimeSerialization(Chronology chrono) throws Exception { in test_ChronoZonedDateTimeSerialization()
DTCKCopticSerialization.java64 import java.time.chrono.Chronology;
77 Chronology chrono = Chronology.of("Coptic"); in test_eraSerialization()
/libcore/ojluni/annotations/mmodule/java/time/chrono/
DChronology.annotated.java68 public interface Chronology extends java.lang.Comparable<java.time.chrono.Chronology> { interface
70 public static java.time.chrono.Chronology from(java.time.temporal.TemporalAccessor temporal) { thro… in from()
72 public static java.time.chrono.Chronology ofLocale(java.util.Locale locale) { throw new RuntimeExce… in ofLocale()
74 public static java.time.chrono.Chronology of(java.lang.String id) { throw new RuntimeException("Stu… in of()
76 public static java.util.Set<java.time.chrono.Chronology> getAvailableChronologies() { throw new Run… in getAvailableChronologies()
128 public int compareTo(java.time.chrono.Chronology other); in compareTo()
/libcore/ojluni/src/main/java/java/time/temporal/
DTemporalQueries.java72 import java.time.chrono.Chronology;
206 public static TemporalQuery<Chronology> chronology() { in chronology()
359 static final TemporalQuery<Chronology> CHRONO = new TemporalQuery<>() {
361 public Chronology queryFrom(TemporalAccessor temporal) {
/libcore/ojluni/src/test/java/time/tck/java/time/format/
DTCKChronoPrinterParser.java65 import java.time.chrono.Chronology;
121 public void test_parseValid_caseSensitive(String text, Chronology expected) { in test_parseValid_caseSensitive()
130 public void test_parseValid_caseSensitive_lowercaseRejected(String text, Chronology expected) { in test_parseValid_caseSensitive_lowercaseRejected()
139 public void test_parseValid_caseInsensitive(String text, Chronology expected) { in test_parseValid_caseInsensitive()
/libcore/luni/src/test/java/libcore/highmemorytest/java/time/format/
DDateTimeFormatterTest.java24 import java.time.chrono.Chronology;
86 for (Chronology chronology : Chronology.getAvailableChronologies()) { in test_format_allLocales_allChronologies()

123