cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r639698 - in /incubator/cxf/branches/2.0.x-fixes: ./ common/common/src/main/java/org/apache/cxf/staxutils/W3CDOMStreamWriter.java
Date Fri, 21 Mar 2008 16:27:57 GMT
Author: dkulp
Date: Fri Mar 21 09:27:45 2008
New Revision: 639698

URL: http://svn.apache.org/viewvc?rev=639698&view=rev
Log:
Merged revisions 639126 via svnmerge from 
https://svn.apache.org/repos/asf/incubator/cxf/trunk

........
  r639126 | dkulp | 2008-03-19 23:03:17 -0400 (Wed, 19 Mar 2008) | 2 lines
  
  Fix constructor to not build factories everytime and use the shared one
........

Modified:
    incubator/cxf/branches/2.0.x-fixes/   (props changed)
    incubator/cxf/branches/2.0.x-fixes/common/common/src/main/java/org/apache/cxf/staxutils/W3CDOMStreamWriter.java

Propchange: incubator/cxf/branches/2.0.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: incubator/cxf/branches/2.0.x-fixes/common/common/src/main/java/org/apache/cxf/staxutils/W3CDOMStreamWriter.java
URL: http://svn.apache.org/viewvc/incubator/cxf/branches/2.0.x-fixes/common/common/src/main/java/org/apache/cxf/staxutils/W3CDOMStreamWriter.java?rev=639698&r1=639697&r2=639698&view=diff
==============================================================================
--- incubator/cxf/branches/2.0.x-fixes/common/common/src/main/java/org/apache/cxf/staxutils/W3CDOMStreamWriter.java
(original)
+++ incubator/cxf/branches/2.0.x-fixes/common/common/src/main/java/org/apache/cxf/staxutils/W3CDOMStreamWriter.java
Fri Mar 21 09:27:45 2008
@@ -24,7 +24,6 @@
 
 import javax.xml.namespace.NamespaceContext;
 import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
 import javax.xml.parsers.ParserConfigurationException;
 import javax.xml.stream.XMLStreamException;
 import javax.xml.stream.XMLStreamWriter;
@@ -33,6 +32,8 @@
 import org.w3c.dom.Document;
 import org.w3c.dom.Element;
 
+import org.apache.cxf.helpers.XMLUtils;
+
 public class W3CDOMStreamWriter implements XMLStreamWriter {
     static final String XML_NS = "http://www.w3.org/2000/xmlns/";
     private Stack<Element> stack = new Stack<Element>();
@@ -42,9 +43,7 @@
     private Map properties = Collections.EMPTY_MAP;
 
     public W3CDOMStreamWriter() throws ParserConfigurationException {
-        DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
-        factory.setNamespaceAware(true);
-        document = factory.newDocumentBuilder().newDocument();
+        document = XMLUtils.newDocument();
     }
 
     public W3CDOMStreamWriter(DocumentBuilder builder) {



Mime
View raw message