使用以下代码打印所有支持的语言 定义:
这些语言定义经常会在一些配置文件中用到,
例如:zh_Hans 表示简体中文
NSArray *localeIdentifiers = [NSLocale availableLocaleIdentifiers];
for(int i=0;i<localeIdentifiers.count;i++){
NSLog(@"%@",localeIdentifiers[i]);
}
打印结果:
为方便阅读,下面的输出结果使用Excel做了排序
zu_ZA
zu
zh_Hant_TW
zh_Hant_MO
zh_Hant_HK
zh_Hant
zh_Hans_SG
zh_Hans_MO
zh_Hans_HK
zh_Hans_CN
zh_Hans
zh
zgh_MA
zgh
yue_HK
yue
yo_NG
yo_BJ
yo
yi_001
yi
yav_CM
yav
xog_UG
xog
wae_CH
wae
vun_TZ
vun
vi_VN
vi
vai_Vaii_LR
vai_Vaii
vai_Latn_LR
vai_Latn
vai
uz_Latn_UZ
uz_Latn
uz_Cyrl_UZ
uz_Cyrl
uz_Arab_AF
uz_Arab
uz
ur_PK
ur_IN
ur
uk_UA
uk
ug_CN
ug
tzm_MA
tzm
twq_NE
twq
tr_TR
tr_CY
tr
to_TO
to
tk_TM
tk
ti_ET
ti_ER
ti
th_TH
th
tg_TJ
tg
teo_UG
teo_KE
teo
te_IN
te
ta_SG
ta_MY
ta_LK
ta_IN
ta
sw_UG
sw_TZ
sw_KE
sw_CD
sw
sv_SE
sv_FI
sv_AX
sv
sr_Latn_XK
sr_Latn_RS
sr_Latn_ME
sr_Latn_BA
sr_Latn
sr_Cyrl_XK
sr_Cyrl_RS
sr_Cyrl_ME
sr_Cyrl_BA
sr_Cyrl
sr
sq_XK
sq_MK
sq_AL
sq
so_SO
so_KE
so_ET
so_DJ
so
sn_ZW
sn
smn_FI
smn
sl_SI
sl
sk_SK
sk
si_LK
si
shi_Tfng_MA
shi_Tfng
shi_Latn_MA
shi_Latn
shi
sg_CF
sg
ses_ML
ses
seh_MZ
seh
se_SE
se_NO
se_FI
se
sbp_TZ
sbp
saq_KE
saq
sah_RU
sah
rwk_TZ
rwk
rw_RW
rw
ru_UA
ru_RU
ru_MD
ru_KZ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
en_LC
en_KY
en_KR
en_KN
en_KI
en_KE
en_JP
en_JM
en_JE
en_IT
en_IS
en_IO
en_IN
en_IM
en_IL
en_IE
en_HU
en_HR
en_HK
en_GY
en_GU
en_GR
en_GM
en_GI
en_GH
en_GG
en_GD
en_GB
en_FR
en_FM
en_FK
en_FJ
en_FI
en_ES
en_ER
en_EE
en_DM
en_DK
en_DG
en_DE
en_CZ
en_CY
en_CX
en_CN
en_CM
en_CK
en_CH
en_CC
en_CA
en_BZ
en_BW
en_BS
en_BR
en_BM
en_BI
en_BE
en_BB
en_BA
en_AU
en_AT
en_AS
en_AL
en_AI
en_AG
en_AD
en_150
en_001
en
el_GR
el_CY
el
ee_TG
ee_GH
ee
ebu_KE
ebu
dz_BT
dz
dyo_SN
dyo
dua_CM
dua
dsb_DE
dsb
dje_NE
dje
de_LU
de_LI
de_DE
de_CH
de_BE
de_AT
de
dav_KE
dav
da_GL
da_DK
da
cy_GB
cy
cs_CZ
cs
ckb_IR
ckb_IQ
ckb
chr_US
chr
cgg_UG
cgg
ce_RU
ce
ca_IT
ca_FR
ca_ES
ca_AD
ca
bs_Latn_BA
bs_Latn
bs_Cyrl_BA
bs_Cyrl
bs
brx_IN
brx
br_FR
br
bo_IN
bo_CN
bo
bn_IN
bn_BD
bn
bm_ML
bm
bg_BG
bg
bez_TZ
bez
bem_ZM
bem
be_BY
be
bas_CM
bas
az_Latn_AZ
az_Latn
az_Cyrl_AZ
az_Cyrl
az
ast_ES
ast
asa_TZ
asa
as_IN
as
ars
ar_YE
ar_TN
ar_TD
ar_SY
ar_SS
ar_SO
ar_SD
ar_SA
ar_QA
ar_PS
ar_OM
ar_MR
ar_MA
ar_LY
ar_LB
ar_KW
ar_KM
ar_JO
ar_IQ
ar_IL
ar_ER
ar_EH
ar_EG
ar_DZ
ar_DJ
ar_BH
ar_AE
ar_001
ar
am_ET
am
ak_GH
ak
agq_CM
agq
af_ZA
af_NA
af