[
https://issues.apache.org/jira/browse/SLING-3413?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13910461#comment-13910461
]
Justin Edelson commented on SLING-3413:
---------------------------------------
proposed patch here: https://codereview.appspot.com/68000044
Examples:
{code}
resource.name;
resource.getName();
{code}
{code}
resource.children; // returns array
resource.getChildren(); // returns map, keyed by name
resource.getChildren(function(r) {}); // invokes function for each child
{code}
> add support for getName() and getChildren() to JS Resource API
> --------------------------------------------------------------
>
> Key: SLING-3413
> URL: https://issues.apache.org/jira/browse/SLING-3413
> Project: Sling
> Issue Type: Improvement
> Components: Scripting
> Reporter: Justin Edelson
> Fix For: Scripting JavaScript 2.0.14
>
>
> The JS API used to wrap Resources doesn't support getting a list of children
> or the resource's name. This should be added.
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)