Conversation
There was a problem hiding this comment.
Hello @jack5505
Thank you for your PR.
-1 As it the PR stands now. There is duplication with what Java provides as well as Lang's own LocaleUtils. For example, using plain Java:
assertEquals("USA", Locale.US.getISO3Country());Using LocaleUtils:
assertEquals("USA", LocaleUtils.languagesByCountry("US").get(0).getISO3Country());As far as phone number data, this likely doesn't belong in a lower-level library like Commons Lang any more than postal code data, but it might belong in Commons Validator. It might be worth discussing finding a home for phone data on the mailing list.
That said, it is likely that we can improve LocaleUtils to achieve some of your use cases.
The changes to FieldUtilsTest.java and StringUtilsTest.java should be reverted as they have nothing to do with the subject of the PR.
Always run mvn by itself and fix all issues before pushing. Right now, all builds fail.
Thank you.
|
Hi thank you for feedback. I will revert not relating part FieldUtilsTest.java and StringUtilsTest.java. But in your LocaleUtils there is no numeric code of country which is give a little bit convenient. |
|
Hello @jack5505 Here are a couple of comments and updates:
|
Thanks for your contribution to Apache Commons! Your help is appreciated!
Before you push a pull request, review this list:
mvn; that'smvnon the command line by itself.