You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Sergey Beryozkin (JIRA)" <ji...@apache.org> on 2013/09/26 12:11:03 UTC

[jira] [Created] (CXF-5301) JSONProvider should add an array key for root if arrayKeys is not empty but top level array has to be produced

Sergey Beryozkin created CXF-5301:
-------------------------------------

             Summary: JSONProvider should add an array key for root if arrayKeys is not empty but top level array has to be produced  
                 Key: CXF-5301
                 URL: https://issues.apache.org/jira/browse/CXF-5301
             Project: CXF
          Issue Type: Improvement
            Reporter: Sergey Beryozkin
            Assignee: Sergey Beryozkin
            Priority: Minor


Setting dropRootElement to true, dropRootElementInXmlStream to false and serializeAsArray is sufficient to do a top level array serialization, example, 

{noformat}
[{"someobject":{"a":"value"}}]
{noformat}

However if someobject is also expected to be an array the setting "arrayKeys" properties loses top level '[]':

{noformat}
{"someobject":[{"a":"value"}]}
{noformat}

Fixing it will lead to

{noformat}
[{"someobject":[{"a":"value"}]]
{noformat}






--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira