为什么没有一个文化枚举? [英] Why isn't there a culture enum?

查看:143
本文介绍了为什么没有一个文化枚举?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

问候,



我想知道为什么没有在C#中的文化预先设定的枚举?
由于文化从来没有改变,总是喜欢NL-NL,EN-GB,EN-US..为什么不使一个枚举为它做的事情只是一点点easy'r?





如前所述文化做改变..但不是全部。为什么不把它保存所有的文化,并提供添加/更改它们的可能性枚举/类类型?


解决方案

由于文化永远不会改变




不是吗? 本文(Microsoft .NET框架4:什么是新全球化)不同意。仅在过去5年中,发生了很多塞尔维亚例如区域发生变化,从而导致新的文化。




在真实的世界,全球化的信息不断,因为在当地市场文化的发展,因为新的标准,更新,改变了文化的敏感信息频繁,或者是因为微软认为对不同的市场更准确的信息,或扩展到更多的市场。



Microsoft .NET框架4支持最小354文化相比于以前的版本最低为203文化。许多这些文化都被添加到完成父链到根中性文化中性。



例如,三因纽特语中立国被添加到现有的文化因纽特语(音节,加拿大)和因纽特语(拉丁语,加拿大)




另外,我想一个枚举本身并没有什么意义。一个CultureInfo的不仅仅是一个名字得多了,和查找提供了更多的灵活性和独立性不受任何政治变化,其中有很多比我们通常认识。


Greetings,

I was wondering why there isn't a pre-set enum for cultures in C#? Since the cultures never change and are always like "nl-NL, en-GB, en-US".. why not make a enum for it to make things just a little bit easy'r ?

[edit]

As stated cultures do change.. but not all. Why not make a enum / class type which holds all the cultures and gives the possibility to add / change them ?

解决方案

"Since the cultures never change"

Don't they? This article (Microsoft .NET Framework 4: What is New in Globalization) disagrees. In the past 5 years alone, a lot has changed in the region of Serbia for example, leading to new Cultures.

In the real world, the globalization information is constantly changing because of cultural developments in the local markets, because of new standards which update the culture sensitive information frequently, or because Microsoft finds more accurate information about different markets or expands into more markets.

Microsoft .NET Framework 4 supports a minimum of 354 cultures compared to a minimum of 203 cultures in the previous release. Many of those cultures are neutrals that were added to complete the parent chain to the root neutral culture.

For example, three Inuktitut neutrals were added to the already existing cultures Inuktitut (Syllabics, Canada) and Inuktitut (Latin, Canada)

Also, I guess an enum itself does not make sense. A CultureInfo is much more than just a name, and a lookup offers more flexibility and independence from any political changes, of which there are many more than we usually realize.

这篇关于为什么没有一个文化枚举?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆