iiop-openjdk/src/main/java/org/wildfly/iiop/openjdk/rmi/ContainerAnalysis.java
protected void fixupCaseNames()
            throws RMIIIOPViolationException {
        ArrayList entries = getContainedEntries();
        boolean[] clash = new boolean[entries.size()];
        String[] upperNames = new String[entries.size()];

        for (int i = 0; i < entries.size(); ++i) {
            AbstractAnalysis aa = (AbstractAnalysis) entries.get(i);

            clash[i] = false;
            upperNames[i] = aa.getIDLName().toUpperCase(Locale.ENGLISH);

            for (int j = 0; j < i; ++j) {
                if (upperNames[i].equals(upperNames[j])) {
                    clash[i] = true;
                    clash[j] = true;
                }
            }
        }

        for (int i = 0; i < entries.size(); ++i) {
            if (!clash[i])
                continue;

            AbstractAnalysis aa = (AbstractAnalysis) entries.get(i);
            boolean noUpper = true;
            String name = aa.getIDLName();
            StringBuffer b = new StringBuffer(name);
            b.append('_');
            for (int j = 0; j < name.length(); ++j) {
                if (!Character.isUpperCase(name.charAt(j)))
                    continue;
                if (noUpper)
                    noUpper = false;
                else
                    b.append('_');
                b.append(j);
            }

            aa.setIDLName(b.toString());
        }
    }
protected void fixupCaseNames()
            throws RMIIIOPViolationException {
        ArrayList entries = getContainedEntries();
        boolean[] clash = new boolean[entries.size()];
        String[] upperNames = new String[entries.size()];

        for (int i = 0; i < entries.size(); ++i) {
            AbstractAnalysis aa = (AbstractAnalysis) entries.get(i);

            clash[i] = false;
            upperNames[i] = aa.getIDLName().toUpperCase(Locale.ENGLISH);

            for (int j = 0; j < i; ++j) {
                if (upperNames[i].equals(upperNames[j])) {
                    clash[i] = true;
                    clash[j] = true;
                }
            }
        }

        for (int i = 0; i < entries.size(); ++i) {
            if (!clash[i])
                continue;

            AbstractAnalysis aa = (AbstractAnalysis) entries.get(i);
            boolean noUpper = true;
            String name = aa.getIDLName();
            StringBuffer b = new StringBuffer(name);
            b.append('_');
            for (int j = 0; j < name.length(); ++j) {
                if (!Character.isUpperCase(name.charAt(j)))
                    continue;
                if (noUpper)
                    noUpper = false;
                else
                    b.append('_');
                b.append(j);
            }

            aa.setIDLName(b.toString());
        }
    }
Fixup names differing only in case.
As specified in section 1.3.2.7.