Yea, this looks like a jettison bug.  Definitely log a bug with them:
http://jira.codehaus.org/browse/JETTISON

You might actually want to try an older version of jettison.   I think 
this might have been introduced in 1.0. (no promisses though)

Dan



On Monday 07 April 2008, rm-ramos wrote:
> Hi all,
>
> I developed a REST web service using CXF's http binding, and I have no
> problem at all with the object  marshaling or the reading of the XML
> outputs. I now need to get JSON output from the same web service, so I
> configured a new ws endpoint in spring, which will return the JSON in
> the "mapped" format.
>
> However, I started to notice odd JSON files being produced, and wrong
> XML object conversion. I'll give this example, in which I need a List
> of labels and a List of value objects (and who contain a list
> themselves) to be returned.
>
> http://www.nabble.com/file/p16538281/xml.xml xml.xml
> http://www.nabble.com/file/p16538281/json.json json.json
>
> The JSON output, as you can see, is strangely groupin values objects,
> two by two, without any particular reason. These are the objects which
> originate such a result:
>
> The response:
> @XmlAccessorType(XmlAccessType.FIELD)
> public class QueryByIdResponse extends GenericResponse {
>
>       @XmlElementWrapper(name="labels")
>       private List<String> label;
>
>       private List<WorkOrderGenericValues> values;
>
>
> WorkOrderGenericValues:
> @XmlAccessorType(XmlAccessType.FIELD)
> public class WorkOrderGenericValues {
>       @XmlElement(name="value")
>       private List<String> stringList;
>
>
> Is this a Jettison bug or am I missing something??
> Any tip would be greatly appreciated!!
>
> Thanks
> Rui Ramos



-- 
J. Daniel Kulp
Principal Engineer, IONA
[EMAIL PROTECTED]
http://www.dankulp.com/blog

Reply via email to