Locale independence
danfickle opened this issue · 1 comments
danfickle commented
We don't want the situation where it works on the developer's machine and not on the server or vice versa because of different locales.
danfickle commented
The user can now specify custom text transformers. If using the rtl-support module for example they can use:
Locale lc = Locale.US;
builder.useUnicodeToLowerTransformer(new ICUTransformers.ICUToLowerTransformer(lc));
builder.useUnicodeToUpperTransformer(new ICUTransformers.ICUToUpperTransformer(lc));
builder.useUnicodeToTitleTransformer(new ICUTransformers.ICUToTitleTransformer(lc));
Another example would be using another locale with the default transformers:
Locale lc = Locale.FRANCE;
builder.useUnicodeToLowerTransformer(new TextUtil.DefaultToLowerTransformer(lc));
builder.useUnicodeToUpperTransformer(new TextUtil.DefaultToUpperTransformer(lc));
builder.useUnicodeToTitleTransformer(new TextUtil.DefaultToTitleTransformer());