abdera-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jmsn...@apache.org
Subject svn commit: r438304 - /incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java
Date Wed, 30 Aug 2006 00:08:27 GMT
Author: jmsnell
Date: Tue Aug 29 17:08:26 2006
New Revision: 438304

URL: http://svn.apache.org/viewvc?rev=438304&view=rev
Log:
Create a document container on clone

Add a method for setting the document

Modified:
    incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java

Modified: incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java
URL: http://svn.apache.org/viewvc/incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java?rev=438304&r1=438303&r2=438304&view=diff
==============================================================================
--- incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java
(original)
+++ incubator/abdera/java/trunk/parser/src/main/java/org/apache/abdera/parser/stax/FOMElement.java
Tue Aug 29 17:08:26 2006
@@ -114,6 +114,10 @@
     return (T)super.getParent();
   }
   
+  protected void setParentDocument(Document parent) {
+    super.setParent((OMContainer)parent);
+  }
+  
   public void setParentElement(Element parent) {
     super.setParent((FOMElement)parent);
   }
@@ -538,7 +542,8 @@
     Object obj = null;
     if (src instanceof Content) obj = ((Content)src).getContentType();
     if (src instanceof Text) obj = ((Text)src).getTextType();
-    el = fomfactory.createElement(src.getQName(), null, factory, obj);
+    el = fomfactory.createElement(
+      src.getQName(), (OMContainer) fomfactory.newDocument(), factory, obj);
     
     return el;
   }



Mime
View raw message