Is WordUtils.capitalizeFully I18N?
I want to use WordUtils.capitalizeFully but am unsure what it does with other languages. Heck, I'm not even sure if Chinese has upper/lo开发者_JS百科wer case. We also use Swedish, German and Russian.
Anyone tried it out?
It seems so:
System.out.println(WordUtils.capitalizeFully("можеше да провериш сам"));
prints
Можеше Да Провериш Сам
The documentation says:
Capitalization uses the unicode title case, normally equivalent to upper case
Chinese and other similar languages (Japanese, Korean, Vietnamese) does not have concept of upper- and lower-case characters (unless transliterated). There are quite a lot languages like this. The only way to be 100% sure is test, since documentation might be erroneous.
I would be more concerned if the utility you mention capitalizes Turkish language correctly - it has strange concept of dotted and dotless I. German could also be a problem, since sharp S should be uppercased to SS.
精彩评论