LocaleEquivalentMaps.java 11.1 KB
Newer Older
1
/*
A
andrew 已提交
2
 * Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 *
 * This code is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License version 2 only, as
 * published by the Free Software Foundation.  Oracle designates this
 * particular file as subject to the "Classpath" exception as provided
 * by Oracle in the LICENSE file that accompanied this code.
 *
 * This code is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 * version 2 for more details (a copy is included in the LICENSE file that
 * accompanied this code).
 *
 * You should have received a copy of the GNU General Public License version
 * 2 along with this work; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 *
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
 * or visit www.oracle.com if you need additional information or have any
 * questions.
 */

package sun.util.locale;

import java.util.HashMap;
import java.util.Map;

/**
 * Locale equivalent map for BCP47 Locale matching
 */
final class LocaleEquivalentMaps {

    static final Map<String, String> singleEquivMap;
    static final Map<String, String[]> multiEquivsMap;
    static final Map<String, String> regionVariantEquivMap;

    static {
        singleEquivMap = new HashMap<>();
        multiEquivsMap = new HashMap<>();
        regionVariantEquivMap = new HashMap<>();

        // This is an auto-generated file and should not be manually edited.
A
andrew 已提交
46 47 48
        //   LSR Revision: 2016-02-10
        singleEquivMap.put("aam", "aas");
        singleEquivMap.put("aas", "aam");
P
peytoia 已提交
49
        singleEquivMap.put("acn", "xia");
A
andrew 已提交
50
        singleEquivMap.put("adp", "dz");
P
peytoia 已提交
51
        singleEquivMap.put("adx", "pcr");
52 53 54
        singleEquivMap.put("ami", "i-ami");
        singleEquivMap.put("art-lojban", "jbo");
        singleEquivMap.put("ase", "sgn-us");
A
andrew 已提交
55
        singleEquivMap.put("aue", "ktz");
56 57 58 59 60
        singleEquivMap.put("ayx", "nun");
        singleEquivMap.put("bfi", "sgn-gb");
        singleEquivMap.put("bjd", "drl");
        singleEquivMap.put("bnn", "i-bnn");
        singleEquivMap.put("bzs", "sgn-br");
P
peytoia 已提交
61
        singleEquivMap.put("cir", "meg");
62 63 64 65 66 67 68 69 70 71 72 73
        singleEquivMap.put("cjr", "mom");
        singleEquivMap.put("cka", "cmr");
        singleEquivMap.put("cmk", "xch");
        singleEquivMap.put("cmn-hans", "zh-cmn-hans");
        singleEquivMap.put("cmn-hant", "zh-cmn-hant");
        singleEquivMap.put("cmr", "cka");
        singleEquivMap.put("csn", "sgn-co");
        singleEquivMap.put("dev", "gav");
        singleEquivMap.put("drh", "khk");
        singleEquivMap.put("drl", "bjd");
        singleEquivMap.put("dse", "sgn-nl");
        singleEquivMap.put("dsl", "sgn-dk");
A
andrew 已提交
74 75 76 77
        singleEquivMap.put("dz", "adp");
        singleEquivMap.put("ema", "uok");
        singleEquivMap.put("en-gb-oed", "en-gb-oxendict");
        singleEquivMap.put("en-gb-oxendict", "en-gb-oed");
78
        singleEquivMap.put("fsl", "sgn-fr");
P
peytoia 已提交
79
        singleEquivMap.put("gal", "ilw");
80 81 82 83
        singleEquivMap.put("gan", "zh-gan");
        singleEquivMap.put("gav", "dev");
        singleEquivMap.put("gsg", "sgn-de");
        singleEquivMap.put("gss", "sgn-gr");
A
andrew 已提交
84
        singleEquivMap.put("gti", "nyc");
85 86 87 88 89 90 91 92 93 94 95 96 97 98 99
        singleEquivMap.put("he", "iw");
        singleEquivMap.put("hle", "sca");
        singleEquivMap.put("hrr", "jal");
        singleEquivMap.put("hsn", "zh-xiang");
        singleEquivMap.put("i-ami", "ami");
        singleEquivMap.put("i-bnn", "bnn");
        singleEquivMap.put("i-klingon", "tlh");
        singleEquivMap.put("i-lux", "lb");
        singleEquivMap.put("i-navajo", "nv");
        singleEquivMap.put("i-pwn", "pwn");
        singleEquivMap.put("i-tao", "tao");
        singleEquivMap.put("i-tay", "tay");
        singleEquivMap.put("i-tsu", "tsu");
        singleEquivMap.put("ibi", "opa");
        singleEquivMap.put("id", "in");
P
peytoia 已提交
100
        singleEquivMap.put("ilw", "gal");
101 102 103 104 105 106 107 108 109 110 111 112 113
        singleEquivMap.put("in", "id");
        singleEquivMap.put("ise", "sgn-it");
        singleEquivMap.put("isg", "sgn-ie");
        singleEquivMap.put("iw", "he");
        singleEquivMap.put("jal", "hrr");
        singleEquivMap.put("jbo", "art-lojban");
        singleEquivMap.put("ji", "yi");
        singleEquivMap.put("jsl", "sgn-jp");
        singleEquivMap.put("jv", "jw");
        singleEquivMap.put("jw", "jv");
        singleEquivMap.put("kgh", "kml");
        singleEquivMap.put("khk", "drh");
        singleEquivMap.put("kml", "kgh");
A
andrew 已提交
114 115 116 117 118
        singleEquivMap.put("koj", "kwv");
        singleEquivMap.put("ktz", "aue");
        singleEquivMap.put("kwq", "yam");
        singleEquivMap.put("kwv", "koj");
        singleEquivMap.put("kxe", "tvd");
119 120
        singleEquivMap.put("lb", "i-lux");
        singleEquivMap.put("lcq", "ppr");
A
andrew 已提交
121 122
        singleEquivMap.put("lii", "raq");
        singleEquivMap.put("lmm", "rmx");
123
        singleEquivMap.put("lrr", "yma");
P
peytoia 已提交
124
        singleEquivMap.put("meg", "cir");
125 126 127
        singleEquivMap.put("mfs", "sgn-mx");
        singleEquivMap.put("mo", "ro");
        singleEquivMap.put("mom", "cjr");
A
andrew 已提交
128
        singleEquivMap.put("mtm", "ymt");
129 130 131
        singleEquivMap.put("nan", "zh-min-nan");
        singleEquivMap.put("nb", "no-bok");
        singleEquivMap.put("ncs", "sgn-ni");
A
andrew 已提交
132
        singleEquivMap.put("ngv", "nnx");
133
        singleEquivMap.put("nn", "no-nyn");
A
andrew 已提交
134
        singleEquivMap.put("nnx", "ngv");
135 136 137 138 139
        singleEquivMap.put("no-bok", "nb");
        singleEquivMap.put("no-nyn", "nn");
        singleEquivMap.put("nsl", "sgn-no");
        singleEquivMap.put("nun", "ayx");
        singleEquivMap.put("nv", "i-navajo");
A
andrew 已提交
140
        singleEquivMap.put("nyc", "gti");
141
        singleEquivMap.put("opa", "ibi");
A
andrew 已提交
142
        singleEquivMap.put("oyb", "thx");
P
peytoia 已提交
143
        singleEquivMap.put("pcr", "adx");
A
andrew 已提交
144 145
        singleEquivMap.put("phr", "pmu");
        singleEquivMap.put("pmu", "phr");
146 147
        singleEquivMap.put("ppr", "lcq");
        singleEquivMap.put("psr", "sgn-pt");
A
andrew 已提交
148 149
        singleEquivMap.put("pub", "puz");
        singleEquivMap.put("puz", "pub");
150
        singleEquivMap.put("pwn", "i-pwn");
A
andrew 已提交
151
        singleEquivMap.put("raq", "lii");
152
        singleEquivMap.put("ras", "tie");
A
andrew 已提交
153
        singleEquivMap.put("rmx", "lmm");
154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181
        singleEquivMap.put("ro", "mo");
        singleEquivMap.put("sca", "hle");
        singleEquivMap.put("sfb", "sgn-be-fr");
        singleEquivMap.put("sfs", "sgn-za");
        singleEquivMap.put("sgg", "sgn-ch-de");
        singleEquivMap.put("sgn-be-fr", "sfb");
        singleEquivMap.put("sgn-be-nl", "vgt");
        singleEquivMap.put("sgn-br", "bzs");
        singleEquivMap.put("sgn-ch-de", "sgg");
        singleEquivMap.put("sgn-co", "csn");
        singleEquivMap.put("sgn-de", "gsg");
        singleEquivMap.put("sgn-dk", "dsl");
        singleEquivMap.put("sgn-es", "ssp");
        singleEquivMap.put("sgn-fr", "fsl");
        singleEquivMap.put("sgn-gb", "bfi");
        singleEquivMap.put("sgn-gr", "gss");
        singleEquivMap.put("sgn-ie", "isg");
        singleEquivMap.put("sgn-it", "ise");
        singleEquivMap.put("sgn-jp", "jsl");
        singleEquivMap.put("sgn-mx", "mfs");
        singleEquivMap.put("sgn-ni", "ncs");
        singleEquivMap.put("sgn-nl", "dse");
        singleEquivMap.put("sgn-no", "nsl");
        singleEquivMap.put("sgn-pt", "psr");
        singleEquivMap.put("sgn-se", "swl");
        singleEquivMap.put("sgn-us", "ase");
        singleEquivMap.put("sgn-za", "sfs");
        singleEquivMap.put("ssp", "sgn-es");
A
andrew 已提交
182
        singleEquivMap.put("suj", "xsj");
183
        singleEquivMap.put("swl", "sgn-se");
A
andrew 已提交
184
        singleEquivMap.put("taj", "tsf");
185 186
        singleEquivMap.put("tao", "i-tao");
        singleEquivMap.put("tay", "i-tay");
A
andrew 已提交
187
        singleEquivMap.put("thx", "oyb");
188 189 190 191
        singleEquivMap.put("tie", "ras");
        singleEquivMap.put("tkk", "twm");
        singleEquivMap.put("tlh", "i-klingon");
        singleEquivMap.put("tlw", "weo");
A
andrew 已提交
192
        singleEquivMap.put("tsf", "taj");
193
        singleEquivMap.put("tsu", "i-tsu");
A
andrew 已提交
194
        singleEquivMap.put("tvd", "kxe");
195
        singleEquivMap.put("twm", "tkk");
A
andrew 已提交
196
        singleEquivMap.put("uok", "ema");
197 198 199 200
        singleEquivMap.put("vgt", "sgn-be-nl");
        singleEquivMap.put("weo", "tlw");
        singleEquivMap.put("wuu", "zh-wuu");
        singleEquivMap.put("xch", "cmk");
P
peytoia 已提交
201
        singleEquivMap.put("xia", "acn");
A
andrew 已提交
202 203
        singleEquivMap.put("xsj", "suj");
        singleEquivMap.put("yam", "kwq");
204 205
        singleEquivMap.put("yi", "ji");
        singleEquivMap.put("yma", "lrr");
A
andrew 已提交
206
        singleEquivMap.put("ymt", "mtm");
P
peytoia 已提交
207
        singleEquivMap.put("yos", "zom");
208
        singleEquivMap.put("yue", "zh-yue");
A
andrew 已提交
209 210
        singleEquivMap.put("yug", "yuu");
        singleEquivMap.put("yuu", "yug");
211 212 213 214 215 216 217
        singleEquivMap.put("zh-cmn-hans", "cmn-hans");
        singleEquivMap.put("zh-cmn-hant", "cmn-hant");
        singleEquivMap.put("zh-gan", "gan");
        singleEquivMap.put("zh-min-nan", "nan");
        singleEquivMap.put("zh-wuu", "wuu");
        singleEquivMap.put("zh-xiang", "hsn");
        singleEquivMap.put("zh-yue", "yue");
P
peytoia 已提交
218
        singleEquivMap.put("zom", "yos");
219 220 221 222

        multiEquivsMap.put("ccq", new String[] {"rki", "ybd"});
        multiEquivsMap.put("cmn", new String[] {"zh-guoyu", "zh-cmn"});
        multiEquivsMap.put("drw", new String[] {"prs", "tnf"});
A
andrew 已提交
223
        multiEquivsMap.put("gfx", new String[] {"vaj", "mwj", "oun"});
224 225 226 227
        multiEquivsMap.put("hak", new String[] {"i-hak", "zh-hakka"});
        multiEquivsMap.put("i-hak", new String[] {"hak", "zh-hakka"});
        multiEquivsMap.put("mry", new String[] {"mst", "myt"});
        multiEquivsMap.put("mst", new String[] {"mry", "myt"});
A
andrew 已提交
228
        multiEquivsMap.put("mwj", new String[] {"vaj", "gfx", "oun"});
229
        multiEquivsMap.put("myt", new String[] {"mry", "mst"});
A
andrew 已提交
230
        multiEquivsMap.put("oun", new String[] {"vaj", "gfx", "mwj"});
231 232 233
        multiEquivsMap.put("prs", new String[] {"drw", "tnf"});
        multiEquivsMap.put("rki", new String[] {"ccq", "ybd"});
        multiEquivsMap.put("tnf", new String[] {"prs", "drw"});
A
andrew 已提交
234
        multiEquivsMap.put("vaj", new String[] {"gfx", "mwj", "oun"});
235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256
        multiEquivsMap.put("ybd", new String[] {"rki", "ccq"});
        multiEquivsMap.put("zh-cmn", new String[] {"cmn", "zh-guoyu"});
        multiEquivsMap.put("zh-guoyu", new String[] {"cmn", "zh-cmn"});
        multiEquivsMap.put("zh-hakka", new String[] {"hak", "i-hak"});

        regionVariantEquivMap.put("-alalc97", "-heploc");
        regionVariantEquivMap.put("-bu", "-mm");
        regionVariantEquivMap.put("-cd", "-zr");
        regionVariantEquivMap.put("-dd", "-de");
        regionVariantEquivMap.put("-de", "-dd");
        regionVariantEquivMap.put("-fr", "-fx");
        regionVariantEquivMap.put("-fx", "-fr");
        regionVariantEquivMap.put("-heploc", "-alalc97");
        regionVariantEquivMap.put("-mm", "-bu");
        regionVariantEquivMap.put("-tl", "-tp");
        regionVariantEquivMap.put("-tp", "-tl");
        regionVariantEquivMap.put("-yd", "-ye");
        regionVariantEquivMap.put("-ye", "-yd");
        regionVariantEquivMap.put("-zr", "-cd");
    }

}