make/jdk/src/classes/build/tools/cldrconverter/SupplementDataParseHandler.java
author tschatzl
Fri, 22 Nov 2019 10:03:38 +0100
changeset 59220 72e15d757e6c
parent 48251 57148c79bd75
permissions -rw-r--r--
8234000: Make HeapRegion::bottom/end/hrm_index const Reviewed-by: kbarrett, sjohanss
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
13583
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
     1
/*
48251
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
     2
 * Copyright (c) 2012, 2017, Oracle and/or its affiliates. All rights reserved.
13583
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
     4
 *
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
     7
 * published by the Free Software Foundation.  Oracle designates this
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
     8
 * particular file as subject to the "Classpath" exception as provided
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
     9
 * by Oracle in the LICENSE file that accompanied this code.
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    10
 *
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    11
 * This code is distributed in the hope that it will be useful, but WITHOUT
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    12
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    13
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    14
 * version 2 for more details (a copy is included in the LICENSE file that
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    15
 * accompanied this code).
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    16
 *
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    17
 * You should have received a copy of the GNU General Public License version
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    18
 * 2 along with this work; if not, write to the Free Software Foundation,
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    19
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    20
 *
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    21
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    22
 * or visit www.oracle.com if you need additional information or have any
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    23
 * questions.
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    24
 */
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    25
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    26
package build.tools.cldrconverter;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    27
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    28
import java.io.File;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    29
import java.io.IOException;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    30
import java.util.HashMap;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    31
import java.util.Map;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    32
import org.xml.sax.Attributes;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    33
import org.xml.sax.InputSource;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    34
import org.xml.sax.SAXException;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    35
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    36
/**
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    37
 * Handles parsing of files in Locale Data Markup Language for SupplementData.xml
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    38
 * and produces a map that uses the keys and values of JRE locale data.
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    39
 */
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    40
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    41
class SupplementDataParseHandler extends AbstractLDMLHandler<Object> {
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    42
    //UNM49 region and composition code used in supplementalData.xml
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    43
    private static final String WORLD = "001";
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    44
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    45
    private static final String JAVA_FIRSTDAY = "firstDayOfWeek";
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    46
    private static final String JAVA_MINDAY = "minimalDaysInFirstWeek";
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    47
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    48
    // The weekData is now in supplementalData.xml,
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    49
    // which is not a locale specific file.
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    50
    // Map for JRE is created locale specific way.
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    51
    // When parsing the locale neutral file (supplementalData.xml),
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    52
    // we need to rely on the country code because
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    53
    // the weekData is listed using country code.
31263
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    54
    //
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    55
    // weekData are generated per each country
13583
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    56
    private final Map<String, Object> firstDayMap;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    57
    private final Map<String, Object> minDaysMap;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    58
31263
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    59
    // Parent locales. These information will only be
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    60
    // generated towards the base meta info, with the format of
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    61
    //
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    62
    // parentLocale.<parent_locale_id>=<child_locale_id>(" "<child_locale_id>)+
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    63
    private final Map<String, String> parentLocalesMap;
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    64
13583
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    65
    SupplementDataParseHandler() {
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    66
        firstDayMap = new HashMap<>();
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    67
        minDaysMap = new HashMap<>();
31263
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    68
        parentLocalesMap = new HashMap<>();
13583
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    69
    }
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    70
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    71
    /**
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    72
     * It returns Map that contains the firstDay and minDays information for
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    73
     * the country. The Map is created in JRE format after obtaining the data
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    74
     * from two Maps, firstDayMap and minDaysMap.
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    75
     *
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    76
     * It returns null when there is no firstDay and minDays for the country
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    77
     * although this should not happen because supplementalData.xml includes
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    78
     * default value for the world ("001") for firstDay and minDays.
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    79
     */
31263
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    80
    Map<String, Object> getData(String id) {
13583
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    81
        Map<String, Object> values = new HashMap<>();
31263
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    82
        if ("root".equals(id)) {
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    83
            parentLocalesMap.keySet().forEach(key -> {
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    84
            values.put(CLDRConverter.PARENT_LOCALE_PREFIX+key,
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    85
                parentLocalesMap.get(key));
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    86
            });
48251
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
    87
            firstDayMap.keySet().forEach(key -> {
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
    88
            values.put(CLDRConverter.CALENDAR_FIRSTDAY_PREFIX+firstDayMap.get(key),
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
    89
                key);
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
    90
            });
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
    91
            minDaysMap.keySet().forEach(key -> {
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
    92
            values.put(CLDRConverter.CALENDAR_MINDAYS_PREFIX+minDaysMap.get(key),
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
    93
                key);
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
    94
            });
31263
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
    95
        }
13583
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    96
        return values.isEmpty() ? null : values;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    97
    }
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    98
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
    99
    @Override
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   100
    public InputSource resolveEntity(String publicID, String systemID) throws IOException, SAXException {
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   101
        // avoid HTTP traffic to unicode.org
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   102
        if (systemID.startsWith(CLDRConverter.SPPL_LDML_DTD_SYSTEM_ID)) {
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   103
            return new InputSource((new File(CLDRConverter.LOCAL_SPPL_LDML_DTD)).toURI().toString());
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   104
        }
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   105
        return null;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   106
    }
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   107
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   108
    /**
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   109
     * JRE requires all the data to be organized by the locale while CLDR 1.4 list
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   110
     * Calendar related data (weekData)in SupplementalData.xml.
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   111
     * startElement stores JRE required data into two Maps,
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   112
     * firstDayMap and minDaysMap.
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   113
     */
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   114
    @Override
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   115
    public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException {
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   116
        // elements we need to actively ignore
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   117
        switch (qName) {
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   118
        case "firstDay":
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   119
            if (!isIgnored(attributes)) {
48251
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   120
                String fd;
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   121
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   122
                switch (attributes.getValue("day")) {
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   123
                    case "sun":
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   124
                        fd = "1";
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   125
                        break;
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   126
                    default:
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   127
                    case "mon":
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   128
                        fd = "2";
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   129
                        break;
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   130
                    case "tue":
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   131
                        fd = "3";
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   132
                        break;
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   133
                    case "wed":
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   134
                        fd = "4";
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   135
                        break;
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   136
                    case "thu":
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   137
                        fd = "5";
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   138
                        break;
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   139
                    case "fri":
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   140
                        fd = "6";
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   141
                        break;
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   142
                    case "sat":
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   143
                        fd = "7";
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   144
                        break;
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   145
                }
57148c79bd75 8176841: Additional Unicode Language-Tag Extensions
naoto
parents: 47216
diff changeset
   146
                firstDayMap.put(attributes.getValue("territories"), fd);
13583
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   147
            }
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   148
            break;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   149
        case "minDays":
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   150
            if (!isIgnored(attributes)) {
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   151
                minDaysMap.put(attributes.getValue("territories"), attributes.getValue("count"));
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   152
            }
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   153
            break;
31263
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
   154
        case "parentLocale":
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
   155
            if (!isIgnored(attributes)) {
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
   156
                parentLocalesMap.put(
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
   157
                    attributes.getValue("parent").replaceAll("_", "-"),
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
   158
                    attributes.getValue("locales").replaceAll("_", "-"));
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
   159
            }
a81a0af34ca0 8008577: Use CLDR Locale Data by Default
naoto
parents: 23010
diff changeset
   160
            break;
13583
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   161
        default:
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   162
            // treat anything else as a container
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   163
            pushContainer(qName, attributes);
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   164
            break;
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   165
        }
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   166
    }
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   167
dc0017b1a452 6336885: RFE: Locale Data Deployment Enhancements
naoto
parents:
diff changeset
   168
}