Search in sources :

Example 1 with ICUResourceBundle

use of com.ibm.icu.impl.ICUResourceBundle in project es6draft by anba.

the class ListFormatObject method createListFormatter.

@SuppressWarnings("deprecation")
private ListFormatter createListFormatter() {
    ULocale locale = ULocale.forLanguageTag(this.locale);
    ICUResourceBundle r = (ICUResourceBundle) UResourceBundle.getBundleInstance(ICUData.ICU_BASE_NAME, locale);
    String resourceStyle = resourceStyle();
    return new ListFormatter(r.getWithFallback("listPattern/" + resourceStyle + "/2").getString(), r.getWithFallback("listPattern/" + resourceStyle + "/start").getString(), r.getWithFallback("listPattern/" + resourceStyle + "/middle").getString(), r.getWithFallback("listPattern/" + resourceStyle + "/end").getString());
}
Also used : ULocale(com.ibm.icu.util.ULocale) ICUResourceBundle(com.ibm.icu.impl.ICUResourceBundle) ListFormatter(com.ibm.icu.text.ListFormatter)

Aggregations

ICUResourceBundle (com.ibm.icu.impl.ICUResourceBundle)1 ListFormatter (com.ibm.icu.text.ListFormatter)1 ULocale (com.ibm.icu.util.ULocale)1