Using XStream to generate the toXml() on JAXB 2.0 classes
seems quite contradictory in itself, wouldn't you say? Why
use JAXB 2.0 in the first place?
Kirill
--- Hanson Char <hanson.char_at_gmail.com> wrote:
> Thinking about the toString() method in jaxb generated
> classes, one
> obvious/easy approach is to generate one (eg via plugin)
> to make use of the
> jarkata commons' ToStringBuilder.reflectionToString(...)
> method.
>
> How about the thought of defining a toXml() to return the
> xml string of the
> current jaxb pojo instance ? AFAIK, such toXml() can be
> easily/nicely done
> using XStream ... But how about the idea of using jaxb
> marshaller instead ?
> Is speed or validation a concern ? (XStream does no
> validation.)
>
> In both instances the generated source would likely to
> incur extra jar
> dependencies.
>
> I don't mind to integrate these extra methods into the
> fluent-api plugin, if
> this is considered sensible.
>
> Thoughts ?
>
> Hanson
>
> On 9/13/06, Kohsuke Kawaguchi <Kohsuke.Kawaguchi_at_sun.com>
> wrote:
> >
> > Hanson Char wrote:
> > > Write your own jaxb plugin ?
> >
> > +1. And if someone is willing to work on it, please let
> us know so that
> > we can host it at http://jaxb2-commons.dev.java.net/
> >
> > --
> > Kohsuke Kawaguchi
> > Sun Microsystems
> kohsuke.kawaguchi_at_sun.com
> >
> >
> >
>
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com