Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improvement: Support user-assigned country codes. #25

Open
derekmahar opened this issue Jun 5, 2015 · 6 comments
Open

Improvement: Support user-assigned country codes. #25

derekmahar opened this issue Jun 5, 2015 · 6 comments

Comments

@derekmahar
Copy link

Please support user-assigned country codes. For example, field Country Identifier in a Global Intermediary Identification Number supports country number 999 for "Other".

@TakahikoKawasaki
Copy link
Owner

Do you mean that "Other" should be added to CountryCode? Or, that CountryCode methods such as getByCode(int) should treat 900-999 differently? Or that some new methods for user-assigned country codes should be added to CountryCode?

Could you clarify what the support means?

@derekmahar
Copy link
Author

"Other" is just an example. I think the implication is that CountryCode
would no longer be a strictly immutable enumeration, but would also contain
a map of numeric or alpha codes to some immutable instance of a user
defined class. Perhaps this would have to be a separate "union" class, say
CountryOrUserAssignedCode that would accept user assignments and would have
it's own getByCode(int) method that would return a standard or
user-assigned code.

On Sun, 7 Jun 2015 11:52 pm Takahiko Kawasaki [email protected]
wrote:

Do you mean that "Other" should be added to CountryCode? Or, that
CountryCode methods such as getByCode(int) should treat 900-999
differently? Or that some new methods for user-assigned country codes
should be added to CountryCode?

Could you clarify what the support means?


Reply to this email directly or view it on GitHub
#25 (comment)
.

@TakahikoKawasaki
Copy link
Owner

Okay, I understood your intention. Are you in a hurry for this extension?

@derekmahar
Copy link
Author

No, not yet, but I was going to implement a workaround myself in a week or
two.

On Mon, 8 Jun 2015 4:16 am Takahiko Kawasaki [email protected]
wrote:

Okay, I understood your intention. Are you in a hurry for this extension?


Reply to this email directly or view it on GitHub
#25 (comment)
.

@mihxil
Copy link

mihxil commented Jun 6, 2019

How about something like https://github.com/mihxil/i18n-regions

@mihxil
Copy link

mihxil commented Jul 1, 2019

I released a 'i18n-regions' which supports user assigned countries, while using nv-i18n for official countries.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants