-
Notifications
You must be signed in to change notification settings - Fork 117
Open
Description
I have a question around producing the following output:
<MsgData><![CDATA[
<foo xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="TOKEN">
<someElement>1111.2222.3333.4444</someElement>
<anotherElement>4000000000000065</anotherElement>
<test>31122019</test>
</foo>]]></MsgData>
How can I use XMLEncoder to produce? This element is nested within others but they've been omitted for clarity. All I can currently think of is encode the internal object separately, convert from Data into a String, and then encode with a CDATA encoding strategy.
I'm also slightly confused around how to conditionally use CData encoding on strings without enabling and disabling it on the encoder as I pass. Any thoughts or ideas would be hugely appreciated!
Metadata
Metadata
Assignees
Labels
No labels