Hi,
I'm trying to marshall a class with a field named endOfLine of type String
which typically contents \r\n.
In the mapping file, I have:
field name=endOfLine type=string
bind-xml name=endofline node=attribute /
/field
The problem is that castor does not replace during the marshalling the
Castor uses the Xerces Serializer so the escaping problem would be
coming from Xerces not Castor. However you can use an element with
xml:space=preserve as such:
foo
endofline xml:space=preserve
/endofline
/foo
The following trick works for me:
?xml version=1.0?
mapping
class
2 matches
Mail list logo