ICU-22960 Use ICUBinary.getRequiredData() to load BreakIterator data

This commit is contained in:
Elango Cheran 2024-11-18 18:22:16 -08:00
parent d6f8a14f8c
commit 5ceee1660f

View file

@ -150,7 +150,7 @@ final class BreakIteratorFactory extends BreakIterator.BreakIteratorServiceShim
String typeKey = typeKeyExt.isEmpty() ? KIND_NAMES[kind] : KIND_NAMES[kind] + typeKeyExt;
brkfname = rb.getStringWithFallback("boundaries/" + typeKey);
String rulesFileName = ICUData.ICU_BRKITR_NAME+ '/' + brkfname;
bytes = ICUBinary.getData(rulesFileName);
bytes = ICUBinary.getRequiredData(rulesFileName);
}
catch (Exception e) {
throw new MissingResourceException(e.toString(),"","");