< prev index next >
src/java.base/share/classes/sun/util/locale/provider/CalendarNameProviderImpl.java
Print this page
rev 17652 : [mq]: 8180469
*** 85,99 ****
// the property "jdk.calendar.japanese.supplemental.era"
// which is always the last element.
Era[] jeras = CalendarSystem.forName("japanese").getEras();
if (jeras.length == value) {
Era supEra = jeras[value - 1]; // 0-based index
! return style == LONG ?
supEra.getName() :
supEra.getAbbreviation();
}
}
return null;
}
name = strings[value];
// If name is empty in standalone, try its `format' style.
if (name.length() == 0
--- 85,105 ----
// the property "jdk.calendar.japanese.supplemental.era"
// which is always the last element.
Era[] jeras = CalendarSystem.forName("japanese").getEras();
if (jeras.length == value) {
Era supEra = jeras[value - 1]; // 0-based index
! if (javatime) {
! return getBaseStyle(style) == NARROW_FORMAT ?
! supEra.getAbbreviation() :
! supEra.getName();
! } else {
! return (style & LONG) != 0 ?
supEra.getName() :
supEra.getAbbreviation();
}
}
+ }
return null;
}
name = strings[value];
// If name is empty in standalone, try its `format' style.
if (name.length() == 0
< prev index next >