• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

Properties files

 
Ranch Hand
Posts: 333
Firefox Browser Windows XP Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

RBControl.properties – Global
RBControl_zh.properties – Language only: Simplified Chinese
RBControl_zh_cn.properties – Region only: China
RBControl_zh_hk.properties – Region only: Hong Kong
RBControl_zh_tw.properties – Taiwan

Source

Hi

I couldn't figure out what does it mean "Region only" and "Language only" ?

and if that is "RBControl_zh_hk.properties – Region only: Hong Kong"

then why is this "RBControl_zh_tw.properties – Taiwan" ?

why isn't that "RBControl_zh_tw.properties – Region only:Taiwan" ?

 
Bartender
Posts: 3648
16
Android Mac OS X Firefox Browser Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ankita

You may not be familiar with ISO country or language codes but that's ok. "ZH" is the language code for Chinese. All others are country codes, HK for Hong Kong, TW for TaiWan, CN for ChiNa. The probable reason they have "region only" properties file is to set apart the locale for internalization (I18N). Also since your example is Chinese related, which can have traditional Chinese (use in HK and TW) and simplified Chinese used in CN. As for the global properties one is most likely ENglish.

Hope this helps.
 
Enkita mody
Ranch Hand
Posts: 333
Firefox Browser Windows XP Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am posting contents of these properties files.

#RBControl.properties
region: global
language: English

#RBControl_zh.properties
language: Simplified Chinese

#RBControl_zh_CN.properties
region: China

#RBControl_zh_HK.properties
region: Hong Kong

#RBControl_zh_TW.properties
region: Taiwan
language: Traditional Chinese

So RBControl_zh_TW.properties file name shows that it contents language code and region code.

RBControl=basename, language code=zh, region code=TW

Now when you see RBControl_zh_HK.properties and RBControl_zh_CN.properties files, there is no language code property.There is only region code.These could be correct for file named with RBControl_HK and RBControl_CN.Correct me if i am wrong.
 
Ranch Hand
Posts: 216
Tomcat Server Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

ankita modi. wrote:I am posting contents of these properties files.

#RBControl.properties
region: global
language: English

#RBControl_zh.properties
language: Simplified Chinese

#RBControl_zh_CN.properties
region: China

#RBControl_zh_HK.properties
region: Hong Kong

#RBControl_zh_TW.properties
region: Taiwan
language: Traditional Chinese

So RBControl_zh_TW.properties file name shows that it contents language code and region code.

RBControl=basename, language code=zh, region code=TW

Now when you see RBControl_zh_HK.properties and RBControl_zh_CN.properties files, there is no language code property.There is only region code.These could be correct for file named with RBControl_HK and RBControl_CN.Correct me if i am wrong.



Have a look at the illustrated example from the same page you posted above.
LINK
 
Enkita mody
Ranch Hand
Posts: 333
Firefox Browser Windows XP Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Nikhil Sagar wrote:Have a look at the illustrated example from the same page you posted above.


My question is about property files not code.That doesn't make any sense.
 
You showed up just in time for the waffles! And this tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic