[jdom-interest] (no subject)

Jason Long jason at supernovasoftware.com
Thu Feb 26 20:49:41 PST 2004


I am not sure I follow.
My code is as follows:
 
Element elt0 = new Element("story");
Element elt1 = (Element) xpath.selectSingleNode(docJDOM);
elt0.addContent(elt1.clone());
 
This is currently serialized as:
 
<story>
  <text>
       Test test test <br/>
       Test test test <br/>
       Test test test <br/>
  </text>
</story>
 
I need it to be as follows:
<![CDATA[".
> Use XMLOutputter.outputElementContent to output the element's content.
> Output "]]>".
 
This assumes you element doesn't contain any CDATA descendants, anything
else that might produce a "]]>" <story>
  <text><![CDATA[
       Test test test <br/>
       Test test test <br/>
       Test test test <br/>
        ]]>
  </text>
</story>
 
 
 
 
Jason Long - CEO and Chief Software Engineer
Supernova Software - supernovasoftware.com
BS Physics, MS Chemical Engineering 
 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://jdom.org/pipermail/jdom-interest/attachments/20040226/2a2f5ac8/attachment.htm


More information about the jdom-interest mailing list