sling-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dan Klco (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (SLING-3368) Add toMap & iterable to resp. JSONObject and JSONArray
Date Tue, 04 Feb 2014 14:58:10 GMT

    [ https://issues.apache.org/jira/browse/SLING-3368?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13890741#comment-13890741
] 

Dan Klco commented on SLING-3368:
---------------------------------

I agree it would be great to make it easier to use the JSONObject and JSONArray.  One thought
might be to make the JSONObject and JSONArray adaptable into Maps and Lists respectively.
 You'd want to serialize the entire JSON structure as well, but that should be fairly easy
to do recursively and that way to can use unmodifyable objects and avoid having to expose/modify
the underlying implementation.

> Add toMap & iterable to resp. JSONObject and JSONArray
> ------------------------------------------------------
>
>                 Key: SLING-3368
>                 URL: https://issues.apache.org/jira/browse/SLING-3368
>             Project: Sling
>          Issue Type: Improvement
>          Components: Commons
>            Reporter: Nicolas Peltier
>            Priority: Minor
>         Attachments: [json]_add_other_ways_to_use_JSONArray_and_JSONObject.patch
>
>
> Map JSONObject.toMap and JSONArray implementing Iterable allows better usage of those
classes.



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Mime
View raw message