AkCollatorFactory { static synchronized Collator forScheme(final CollationSpecifier specifier) { RuleBasedCollator collator = (RuleBasedCollator) sourceMap.get(specifier.toString()); if (collator == null) { collator = specifier.createCollator(); sourceMap.put(specifier.toString(), collator); } collator = collator.cloneAsThawed(); return collator; }  static void setCollationMode(String modeString); static void setCollationMode(Mode m); static Mode getCollationMode(); static AkCollator getAkCollator(final String scheme); static AkCollator getAkCollator(final int collatorId); static T getKeyByValue(Map<T, E> map, E value); final static int UCS_BINARY_ID; final static String UCS_BINARY; final static AkCollator UCS_BINARY_COLLATOR; }
@Test(expected = UnsupportedCollationException.class) public void collationBadScheme() throws Exception { CollationSpecifier collationSpecifier = new CollationSpecifier("en_us_bad_arguments"); AkCollatorFactory.forScheme(collationSpecifier); }