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

Can't map from a Windows Timezone name to a set IANA timezone Ids #39

Closed
gavinbarron opened this issue Mar 31, 2018 · 1 comment
Closed

Comments

@gavinbarron
Copy link

Given a Windows timezone name I'd like the list of IANA ids that match

@mattjohnsonpint
Copy link
Owner

Sorry, but are you talking about Windows time zone IDs, or the localized strings in the CLDR language data?

If you're talking about Windows IDs, then generally this is supported by TimeZoneConverter (though currently there's not a method to return an array, but that could be certainly added there).

However, your PR appears to be about reverse-mapping the localization, and it appears to be going through every language in the data for any possible match. I'm a bit concerned about the performance implications of such a linear search, as well as conflicts or oddities that may be present between languages.

Generally, with TimeZoneNames, we're producing a human-readable string for display. Thus, a reverse function such as yours would be useful when parsing human-readable. As such, we would need to think about all sorts of other things that go along with natural language processing. At a minimum, I'd want to constrain it to a specific language or set of languages, rather than searching them all.

Can you elaborate about your intended usage?
Thanks.

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

2 participants