Class ListChildrenTag

java.lang.Object
javax.servlet.jsp.tagext.TagSupport
org.apache.sling.scripting.jsp.taglib.ListChildrenTag
All Implemented Interfaces:
Serializable, IterationTag, JspTag, Tag

public class ListChildrenTag extends TagSupport
Tag for listing the children of a Resource. The children will be returned as an Iterator of Resource objects in the specified variable.
See Also:
  • Constructor Details

    • ListChildrenTag

      public ListChildrenTag()
  • Method Details

    • doEndTag

      public int doEndTag()
      Description copied from class: TagSupport
      Default processing of the end tag returning EVAL_PAGE.
      Specified by:
      doEndTag in interface Tag
      Overrides:
      doEndTag in class TagSupport
      Returns:
      EVAL_PAGE
      See Also:
    • getResource

      public Resource getResource()
      Gets the resource of which to list the children.
      Returns:
      the Sling Resource
    • getVar

      public String getVar()
      Gets the variable name to which to save the list of children.
      Returns:
      the variable name
    • setResource

      public void setResource(Resource resource)
      Sets the resource of which to list the children.
      Parameters:
      resource - the Sling Resource
    • setVar

      public void setVar(String var)
      Sets the variable name to which to save the list of children.
      Parameters:
      var - the variable name