Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 79206 | Differences between
and this patch

Collapse All | Expand All

(-)src/org/apache/xerces/impl/XMLDTDScannerImpl.java.orig (-5 / +5 lines)
Lines 1198-1218 Link Here
1198
1198
1199
            // call handler
1199
            // call handler
1200
            if (fDTDHandler != null) {
1200
            if (fDTDHandler != null) {
1201
                String[] enum = null;
1201
                String[] enum1 = null;
1202
                if (fEnumerationCount != 0) {
1202
                if (fEnumerationCount != 0) {
1203
                    enum = new String[fEnumerationCount];
1203
                    enum1 = new String[fEnumerationCount];
1204
                    System.arraycopy(fEnumeration, 0, enum,
1204
                    System.arraycopy(fEnumeration, 0, enum1,
1205
                                     0, fEnumerationCount);
1205
                                     0, fEnumerationCount);
1206
                }
1206
                }
1207
                // Determine whether the default value to be passed should be null. 
1207
                // Determine whether the default value to be passed should be null. 
1208
                // REVISIT: should probably check whether fLiteral.ch is null instead. LM.
1208
                // REVISIT: should probably check whether fLiteral.ch is null instead. LM.
1209
                if (defaultType!=null && (defaultType.equals("#REQUIRED") || 
1209
                if (defaultType!=null && (defaultType.equals("#REQUIRED") || 
1210
                                          defaultType.equals("#IMPLIED"))) {
1210
                                          defaultType.equals("#IMPLIED"))) {
1211
                    fDTDHandler.attributeDecl(elName, name, type, enum,
1211
                    fDTDHandler.attributeDecl(elName, name, type, enum1,
1212
                                              defaultType, null, null, null);
1212
                                              defaultType, null, null, null);
1213
                }
1213
                }
1214
                else {
1214
                else {
1215
                    fDTDHandler.attributeDecl(elName, name, type, enum,
1215
                    fDTDHandler.attributeDecl(elName, name, type, enum1,
1216
                                              defaultType, fLiteral, fLiteral2, null);
1216
                                              defaultType, fLiteral, fLiteral2, null);
1217
                }
1217
                }
1218
            }
1218
            }
(-)src/org/apache/xerces/impl/xs/XSGrammarBucket.java.orig (-3 / +3 lines)
Lines 180-189 Link Here
180
        int count = fGrammarRegistry.size() + (fNoNSGrammar==null ? 0 : 1);
180
        int count = fGrammarRegistry.size() + (fNoNSGrammar==null ? 0 : 1);
181
        SchemaGrammar[] grammars = new SchemaGrammar[count];
181
        SchemaGrammar[] grammars = new SchemaGrammar[count];
182
        // get grammars with target namespace
182
        // get grammars with target namespace
183
        Enumeration enum = fGrammarRegistry.elements();
183
        Enumeration enum1 = fGrammarRegistry.elements();
184
        int i = 0;
184
        int i = 0;
185
        while (enum.hasMoreElements())
185
        while (enum1.hasMoreElements())
186
            grammars[i++] = (SchemaGrammar)enum.nextElement();
186
            grammars[i++] = (SchemaGrammar)enum1.nextElement();
187
        // add the grammar without target namespace, if any
187
        // add the grammar without target namespace, if any
188
        if (fNoNSGrammar != null)
188
        if (fNoNSGrammar != null)
189
            grammars[count-1] = fNoNSGrammar;
189
            grammars[count-1] = fNoNSGrammar;
(-)src/org/apache/xerces/impl/xs/traversers/XSAttributeChecker.java.orig (-3 / +3 lines)
Lines 1537-1547 Link Here
1537
    // REVISIT: pass the proper element node to reportSchemaError
1537
    // REVISIT: pass the proper element node to reportSchemaError
1538
    public void checkNonSchemaAttributes(XSGrammarBucket grammarBucket) {
1538
    public void checkNonSchemaAttributes(XSGrammarBucket grammarBucket) {
1539
        // for all attributes
1539
        // for all attributes
1540
        Enumeration enum = fNonSchemaAttrs.keys();
1540
        Enumeration enum1 = fNonSchemaAttrs.keys();
1541
        XSAttributeDecl attrDecl;
1541
        XSAttributeDecl attrDecl;
1542
        while (enum.hasMoreElements()) {
1542
        while (enum1.hasMoreElements()) {
1543
            // get name, uri, localpart
1543
            // get name, uri, localpart
1544
            String attrRName = (String)enum.nextElement();
1544
            String attrRName = (String)enum1.nextElement();
1545
            String attrURI = attrRName.substring(0,attrRName.indexOf(','));
1545
            String attrURI = attrRName.substring(0,attrRName.indexOf(','));
1546
            String attrLocal = attrRName.substring(attrRName.indexOf(',')+1);
1546
            String attrLocal = attrRName.substring(attrRName.indexOf(',')+1);
1547
            // find associated grammar
1547
            // find associated grammar
(-)src/org/apache/xerces/util/AugmentationsImpl.java.orig (-3 / +3 lines)
Lines 311-320 Link Here
311
        public String toString() {
311
        public String toString() {
312
            StringBuffer buff = new StringBuffer();
312
            StringBuffer buff = new StringBuffer();
313
            buff.append("LargeContainer");
313
            buff.append("LargeContainer");
314
            Enumeration enum = fAugmentations.keys();
314
            Enumeration enum1 = fAugmentations.keys();
315
315
316
            while (enum.hasMoreElements()) {
316
            while (enum1.hasMoreElements()) {
317
                Object key = enum.nextElement();
317
                Object key = enum1.nextElement();
318
                buff.append("\nkey == ");
318
                buff.append("\nkey == ");
319
                buff.append(key);
319
                buff.append(key);
320
                buff.append("; value == ");
320
                buff.append("; value == ");
(-)src/org/apache/xerces/util/NamespaceSupport.java.orig (-3 / +3 lines)
Lines 125-133 Link Here
125
    public NamespaceSupport(NamespaceContext context) {
125
    public NamespaceSupport(NamespaceContext context) {
126
        pushContext();
126
        pushContext();
127
        // copy declaration in the context
127
        // copy declaration in the context
128
        Enumeration enum = context.getAllPrefixes();
128
        Enumeration enum1 = context.getAllPrefixes();
129
        while (enum.hasMoreElements()){
129
        while (enum1.hasMoreElements()){
130
            String prefix = (String)enum.nextElement();
130
            String prefix = (String)enum1.nextElement();
131
            String uri = context.getURI(prefix);
131
            String uri = context.getURI(prefix);
132
            declarePrefix(prefix, uri);
132
            declarePrefix(prefix, uri);
133
        }
133
        }
(-)src/org/apache/xml/serialize/HTMLSerializer.java.orig (-4 / +4 lines)
Lines 346-357 Link Here
346
                preserveSpace = true;
346
                preserveSpace = true;
347
347
348
            if ( addNSAttr ) {
348
            if ( addNSAttr ) {
349
                Enumeration enum;
349
                Enumeration enum1;
350
350
351
                enum = _prefixes.keys();
351
                enum1 = _prefixes.keys();
352
                while ( enum.hasMoreElements() ) {
352
                while ( enum1.hasMoreElements() ) {
353
                    _printer.printSpace();
353
                    _printer.printSpace();
354
                    value = (String) enum.nextElement();
354
                    value = (String) enum1.nextElement();
355
                    name = (String) _prefixes.get( value );
355
                    name = (String) _prefixes.get( value );
356
                    if ( name.length() == 0 ) {
356
                    if ( name.length() == 0 ) {
357
                        _printer.printText( "xmlns=\"" );
357
                        _printer.printText( "xmlns=\"" );
(-)src/org/apache/xml/serialize/XMLSerializer.java.orig (-4 / +4 lines)
Lines 374-385 Link Here
374
            }
374
            }
375
375
376
            if (_prefixes != null) {
376
            if (_prefixes != null) {
377
                Enumeration enum;
377
                Enumeration enum1;
378
378
379
                enum = _prefixes.keys();
379
                enum1 = _prefixes.keys();
380
                while (enum.hasMoreElements()) {
380
                while (enum1.hasMoreElements()) {
381
                    _printer.printSpace();
381
                    _printer.printSpace();
382
                    value = (String) enum.nextElement();
382
                    value = (String) enum1.nextElement();
383
                    name = (String) _prefixes.get( value );
383
                    name = (String) _prefixes.get( value );
384
                    if (name.length() == 0) {
384
                    if (name.length() == 0) {
385
                        _printer.printText( "xmlns=\"" );
385
                        _printer.printText( "xmlns=\"" );
(-)samples/xni/PSVIWriter.java.orig (-3 / +3 lines)
Lines 1147-1157 Link Here
1147
		printElement("prefix", "xml");
1147
		printElement("prefix", "xml");
1148
		printElement("namespaceName", NamespaceContext.XML_URI);
1148
		printElement("namespaceName", NamespaceContext.XML_URI);
1149
        printUnIndentTag("</namespace>");
1149
        printUnIndentTag("</namespace>");
1150
		Enumeration enum = fNamespaceContext.getAllPrefixes();
1150
		Enumeration enum1 = fNamespaceContext.getAllPrefixes();
1151
		while (enum.hasMoreElements()) {
1151
		while (enum1.hasMoreElements()) {
1152
            printIndentTag("<namespace>");
1152
            printIndentTag("<namespace>");
1153
1153
1154
			String prefix = (String) enum.nextElement();
1154
			String prefix = (String) enum1.nextElement();
1155
			String uri = fNamespaceContext.getURI(prefix);
1155
			String uri = fNamespaceContext.getURI(prefix);
1156
			printElement("prefix", prefix);
1156
			printElement("prefix", prefix);
1157
			printElement("namespaceName", uri);
1157
			printElement("namespaceName", uri);

Return to bug 79206