You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by mr...@apache.org on 2006/09/10 22:38:29 UTC

svn commit: r442002 - /xerces/java/trunk/src/org/apache/xerces/impl/xs/traversers/XSDAbstractTraverser.java

Author: mrglavas
Date: Sun Sep 10 13:38:28 2006
New Revision: 442002

URL: http://svn.apache.org/viewvc?view=rev&rev=442002
Log:
Use the SymbolTable instead of calling String.intern() directly.

Modified:
    xerces/java/trunk/src/org/apache/xerces/impl/xs/traversers/XSDAbstractTraverser.java

Modified: xerces/java/trunk/src/org/apache/xerces/impl/xs/traversers/XSDAbstractTraverser.java
URL: http://svn.apache.org/viewvc/xerces/java/trunk/src/org/apache/xerces/impl/xs/traversers/XSDAbstractTraverser.java?view=diff&rev=442002&r1=442001&r2=442002
==============================================================================
--- xerces/java/trunk/src/org/apache/xerces/impl/xs/traversers/XSDAbstractTraverser.java (original)
+++ xerces/java/trunk/src/org/apache/xerces/impl/xs/traversers/XSDAbstractTraverser.java Sun Sep 10 13:38:28 2006
@@ -1,5 +1,5 @@
 /*
- * Copyright 2001-2005 The Apache Software Foundation.
+ * Copyright 2001-2006 The Apache Software Foundation.
  * 
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -31,18 +31,15 @@
 import org.apache.xerces.impl.xs.XSElementDecl;
 import org.apache.xerces.impl.xs.XSParticleDecl;
 import org.apache.xerces.impl.xs.XSWildcardDecl;
-import org.apache.xerces.xs.XSObjectList;
-import org.apache.xerces.xs.XSTypeDefinition;
-import org.apache.xerces.impl.xs.opti.ElementImpl;
 import org.apache.xerces.impl.xs.util.XInt;
 import org.apache.xerces.impl.xs.util.XSObjectListImpl;
 import org.apache.xerces.util.DOMUtil;
 import org.apache.xerces.util.NamespaceSupport;
 import org.apache.xerces.util.SymbolTable;
 import org.apache.xerces.xni.QName;
+import org.apache.xerces.xs.XSObjectList;
+import org.apache.xerces.xs.XSTypeDefinition;
 import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.Text;
 
 /**
  * Class <code>XSDAbstractTraverser</code> serves as the base class for all
@@ -156,7 +153,7 @@
                     prefix = rawname.substring(0,colonIndex);
                     localpart = rawname.substring(colonIndex+1);
                 }
-                String uri = schemaDoc.fNamespaceSupport.getURI(prefix.intern());
+                String uri = schemaDoc.fNamespaceSupport.getURI(fSymbolTable.addSymbol(prefix));
                 if (!annotationDecl.getAttributeNS(uri, localpart).equals("")) {
                     i++; // skip the next value, too
                     continue;
@@ -219,7 +216,7 @@
                     prefix = rawname.substring(0,colonIndex);
                     localpart = rawname.substring(colonIndex+1);
                 }
-                String uri = schemaDoc.fNamespaceSupport.getURI(prefix.intern());
+                String uri = schemaDoc.fNamespaceSupport.getURI(fSymbolTable.addSymbol(prefix));
                 localStrBuffer.append(rawname)
                 .append("=\"");
                 String value = (String)annotationLocalAttrs.elementAt(i++);



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@xerces.apache.org
For additional commands, e-mail: commits-help@xerces.apache.org