cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anto...@apache.org
Subject svn commit: r396184 - /cocoon/trunk/core/cocoon-core/src/main/java/org/apache/cocoon/xml/dom/DOMStreamer.java
Date Sun, 23 Apr 2006 00:11:29 GMT
Author: antonio
Date: Sat Apr 22 17:11:27 2006
New Revision: 396184

URL: http://svn.apache.org/viewcvs?rev=396184&view=rev
Log:
Merging from branch 2.1.

Modified:
    cocoon/trunk/core/cocoon-core/src/main/java/org/apache/cocoon/xml/dom/DOMStreamer.java

Modified: cocoon/trunk/core/cocoon-core/src/main/java/org/apache/cocoon/xml/dom/DOMStreamer.java
URL: http://svn.apache.org/viewcvs/cocoon/trunk/core/cocoon-core/src/main/java/org/apache/cocoon/xml/dom/DOMStreamer.java?rev=396184&r1=396183&r2=396184&view=diff
==============================================================================
--- cocoon/trunk/core/cocoon-core/src/main/java/org/apache/cocoon/xml/dom/DOMStreamer.java
(original)
+++ cocoon/trunk/core/cocoon-core/src/main/java/org/apache/cocoon/xml/dom/DOMStreamer.java
Sat Apr 22 17:11:27 2006
@@ -64,7 +64,7 @@
 public class DOMStreamer implements XMLProducer, Recyclable {
 
     /** The transformer factory shared by all instances (only used by DefaultDOMStreamer)
*/
-    protected static final TransformerFactory FACTORY = TransformerFactory.newInstance();
+    private static final TransformerFactory FACTORY = TransformerFactory.newInstance();
 
     /** Default value for normalizeNamespaces. */
     private static final boolean DEFAULT_NORMALIZE_NAMESPACES = true;
@@ -505,10 +505,10 @@
                 namespace = "http://www.w3.org/2000/xmlns/";
             } else {
                 // Attribute name for this prefix's declaration
-                String declname = (prefix.equals("")) ? "xmlns" : "xmlns:" + prefix;
+                String declname = (prefix.length() == 0) ? "xmlns" : "xmlns:" + prefix;
 
                 // Scan until we run out of Elements or have resolved the namespace
-                while ((null != parent) && (null == namespace)
+                while ((null != parent)
                    && (((type = parent.getNodeType()) == Node.ELEMENT_NODE)
                        || (type == Node.ENTITY_REFERENCE_NODE))) {
                     if (type == Node.ELEMENT_NODE) {
@@ -564,8 +564,8 @@
                             //System.out.println("ending prefix mapping " + (String) entry.getKey());
                         }
                     }
-
                     currentElementInfo = currentElementInfo.parent;
+                    break;
                 case Node.DOCUMENT_NODE:
                 case Node.CDATA_SECTION_NODE:
                     break;



Mime
View raw message