I'm not able to reproduce this issue. Which version of Axiom are you using?

Andreas

On Thu, Feb 5, 2009 at 03:32, Wang Zhi Hao  (NCSI SZ)
<zhw...@ncsi.com.cn> wrote:
> Hi,
>
>
>
> I encounter a problem when I using the cloneElement function, the CDATA
> will be lost after the clone operation, for example:
>
>
>
> My xml message is:
>
>
>
> <?xml version='1.0' encoding='utf-8'?>
>
> <map>
>
> <name>FOTO</name>
>
> <cdata><![CDATA[<aaa>]]></cdata>
>
> </map>
>
>
>
> After I using the cloneElement function, the clone message I got become:
>
>
>
> <?xml version='1.0' encoding='utf-8'?>
>
> <map>
>
> <name>FOTO</name>
>
> <cdata><![CDATA[]]></cdata>
>
> </map>
>
>
>
> Could you help to look at this? The codes I using is like below:
>
>
>
>    InputStream inputStream   =   new ByteArrayInputStream(xmlMessage);
>
>    XMLStreamReader parser =
> XMLInputFactory.newInstance().createXMLStreamReader(inputStream);
>
>    StAXBuilder builder = new StAXOMBuilder(parser);
>
> OMDocument document = builder.getDocument();
>
>
>
> OMElement documentElement = document.getOMDocumentElement();
>
> documentElement.build();
>
>
>
> OMElement cloneElement = documentElement.cloneOMElement();
>
>
>
> Thanks & Regards!
>
>
>
> Zhi Hao
>
>
>
>

Reply via email to