Hi Andreas,

Andreas Sachs wrote:

> Hi,
> after upgrading xstream from 1.3.1 to 1.4.2 and jettison 1.0.1 to 1.2 (or
> 1.3.1) the generated json string changed. I could also change the
> javascript processing of the json string, but the new version looks
> strange to me.
> 
> I try to serialize the following object tree:
> 
> class userlist {
> private List<User> users;
> }
> 
> class User {
> private name;
> private vorname;
> }
> 
> 
> After the upgrade the json string contains collections at two different
> levels.
> 
> Old
> {"userlist":{"users":{"user":[{"name":"x","vorname":"y"},
{"name":"x","vorname":"y"}]}}}
> 
> New
> {"userlist":{"users":[{"user":[{"name":"x","vorname":"y"},
{"name":"x","vorname":"y"}]}]}}
> 
> Is this ok and i should change my code? or is this a bug?

The JSON code produced by Jettison has slightly changed switching from 1.0.1 
to 1.2. If you had no problems until now, you should be able to use 1.0.1 
still. Jettison 1.1 and 1.3 are unfortunately creating a lot of problems and 
as of today all I can say is that they do not pass XStream's internal unit 
tests.

Cheers,
Jörg


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to