Re: [Simple-support] Serialization of nested lists, arrays
Brought to you by:
niallg
|
From: Niall G. <gal...@ya...> - 2012-04-28 01:40:35
|
You can use a Converter to manipulate the XML directly, to convert attributes take a look at Transform.
--- On Fri, 27/4/12, Bernhard Groll <ber...@tu...> wrote:
From: Bernhard Groll <ber...@tu...>
Subject: Re: [Simple-support] Serialization of nested lists, arrays
To: "Niall Gallagher" <gal...@ya...>
Cc: "sim...@li..." <sim...@li...>
Received: Friday, 27 April, 2012, 6:40 AM
Hi Niall,
you wrote (2012-04-26T15:18:13-0700):
> You can create an object that contains a list and make the list
> inline like so. @ElementListList<Blah>list;
> class Blah { @ElementList(inline=true) List<BigDecimal> inline;}
Thanks for the idea. But while this would work for the XML output, the
necessary wrapper class (Blah) would be bad design on the Java side.
On a related topic, is there a way to make text lists like the default
serializations of arrays whitespace-separated instead of
comma-separated? Looking at XML schema descriptions the former seems to
be the norm.
Best regards,
Bernhard
|