Actually there is no specific support for CDATA  sections.
When it was supported by XML Schema, we used to map it to
a Java string.
For your problem, you might want to use an AnyNode and the xsd:any in your
XML Schema.

Hope this helps,

Arnaud
> -----Original Message-----
> From: Ozgur Balsoy [mailto:[EMAIL PROTECTED]]
> Sent: Friday, July 27, 2001 9:29 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [castor-dev] Please Help! Need CDATA
>
>
> I had a similar problem with CDATA sections. It looks like there is no
> support for CDATA in Castor (or I could not find any help).
> Besides, xsd:CDATA is removed from the final XML Schema recommendation.
>
> As a solution, you can make your element a 'xsd:string' and set
> white space
> facet to 'preserve'. Two drawbacks:
> - you cannot use indentation feature for marshalling.
> - '<' '>' and other special characters are translated into &lt; &gt; etc.
>
> Hope this helps.
>
> Ozgur Balsoy
>
> > -----Original Message-----
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of
> > Michel Smits
> > Sent: Friday, July 27, 2001 8:56 AM
> > To: [EMAIL PROTECTED]
> > Subject: [castor-dev] Please Help! Need CDATA
> >
> >
> > Hello there,
> >
> > I've already posted this question (slightly different) but I must make a
> > decision whether or not to continue with Castor... (the
> > alternatives do not
> > look that great but..)
> >
> > When using Castor-J (0.9.3 and Xerces 1.4.2) xml binding, do
> the generated
> > classes support CDATA text???
> >
> > The reason for this is I have an element containing unformatted HTML.
> > So far, I keep losing the <![CDATA[..]]> tag (possibly causing
> > errors during
> > marshalling).
> > To test this, unmarshal and then marshal an xml document
> > (containing CDATA).
> >
> > Thanks,
> >  Michel Smits
> >  [EMAIL PROTECTED]
> >
> > -----------------------------------------------------------
> > If you wish to unsubscribe from this mailing, send mail to
> > [EMAIL PROTECTED] with a subject of:
> >     unsubscribe castor-dev
> >
> >
>
> -----------------------------------------------------------
> If you wish to unsubscribe from this mailing, send mail to
> [EMAIL PROTECTED] with a subject of:
>       unsubscribe castor-dev

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

Reply via email to