Werner and Thomas-

You can also look at the following thread in the archives:

http://www.mail-archive.com/[email protected]/msg02100.html

which discusses using xml attributes to preserve whitespace.

Stephen


On 2/23/06, Werner Guttmann <[EMAIL PROTECTED]> wrote:
> Thomas,
>
> Can you please open a new issue at
> http://jira.codehaus.org/browse/CASTOR, and attach all relevant
> information ?
>
> Thanks
> Werner Guttmann
>
> > -----Original Message-----
> > From: Thomas Tatzel [mailto:[EMAIL PROTECTED]
> > Sent: Donnerstag, 23. Februar 2006 15:49
> > To: [email protected]
> > Subject: [castor-dev] Unmarshaller is not preserving
> > whitespaces for org.w3c.dom.Node, for InputSource and Reader it does
> >
> > Hello together,
> >
> > because of performance problems in my application I switched
> > from the default AXIS implementation to the Castor
> > (de)serializer (Version 0.9.9.1) in my Web Service.
> > Thus I get the problem, that the Deserializer is calling the
> > Castor unmarshaller class with the method ?public static
> > Object unmarshal(Class c, Node node)?.
> >
> > This method cause the problem, that all whitespaces get
> > remove. But my model defines one of the member as CHAR(3) and
> > the value out of my
> > database is ?   ? (three spaces) and that is what I expect.
> > For that data
> > constellation I get a Castor ValidationException.
> >
> > So I did a little bit research an found in the
> > org.exolab.castor.xml.Unmarshaller class for the methods
> > ?public static Object unmarshal(Class c, Reader reader)? and
> > ?public static Object unmarshal(Class c, InputSource source)?
> > the following lines
> >
> >         //-- for backward compatibility with Castor versions
> >         //-- prior to version 0.9.5.3
> >         unmarshaller.setWhitespacePreserve(true);
> >
> > But for method ?public static Object unmarshal(Class c, Node
> > node)? there is no whitespace preserving.
> >
> > So my question, why the Unmarshall class has for their
> > unmarshall methods different whitespace preserving handling?
> > I would prefer whitespace preserving for all methods by
> > default and enable/disable it by a parameter in the
> > castor.properties. What do you think?
> >
> > Regards
> > Thomas
> >
> >
> >
> > --
> >
> > Diese E-Mail enthaelt vertrauliche und/oder rechtlich
> > geschuetzte Informationen. Wenn Sie nicht der richtige
> > Adressat sind oder diese E-Mail irrtuemlich erhalten haben,
> > informieren Sie bitte sofort den Absender und vernichten Sie
> > diese Mail. Das unerlaubte Kopieren sowie die unbefugte
> > Weitergabe dieser Mail ist nicht gestattet.
> >
> > This e-mail may contain confidential and/or privileged
> > information. If you are not the intended recipient (or have
> > received this e-mail in error) please notify the sender
> > immediately and destroy this e-mail. Any unauthorized
> > copying, disclosure or distribution of the material in this
> > e-mail is strictly forbidden.
> >
> >
> > -------------------------------------------------
> > If you wish to unsubscribe from this list, please send an
> > empty message to the following address:
> >
> > [EMAIL PROTECTED]
> > -------------------------------------------------
> >
> >
> >
>
> -------------------------------------------------
> If you wish to unsubscribe from this list, please
> send an empty message to the following address:
>
> [EMAIL PROTECTED]
> -------------------------------------------------
>
>

Reply via email to