Package org.xwiki.tree
Interface TreeNode
-
- All Known Subinterfaces:
Tree
- All Known Implementing Classes:
AbstractCompositeTree,AbstractTree,AbstractTreeNode
@Role public interface TreeNodeThe interface used to represent a node in a tree structure.- Since:
- 8.3M2, 7.4.5
- Version:
- $Id: 4dc5d49e274fd26e614e438846215fff9d8728aa $
-
-
Field Summary
Fields Modifier and Type Field Description static StringPROPERTY_EXCLUSIONSThe property that specifies the nodes to exclude.static StringPROPERTY_FILTERSThe property that specifies the filters to apply on the tree.static StringPROPERTY_ORDER_BYThe property that specifies how the child nodes are sorted.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description intgetChildCount(String nodeId)Retrieve the number of children of the specified node.List<String>getChildren(String nodeId, int offset, int limit)Retrieve the children of the specified node.StringgetParent(String nodeId)Retrieve the parent of the specified node.Map<String,Object>getProperties()Retrieve the properties that can be used to configure the tree node.
-
-
-
Field Detail
-
PROPERTY_ORDER_BY
static final String PROPERTY_ORDER_BY
The property that specifies how the child nodes are sorted.- See Also:
- Constant Field Values
-
PROPERTY_EXCLUSIONS
static final String PROPERTY_EXCLUSIONS
The property that specifies the nodes to exclude.- See Also:
- Constant Field Values
-
PROPERTY_FILTERS
static final String PROPERTY_FILTERS
The property that specifies the filters to apply on the tree.- See Also:
- Constant Field Values
-
-
Method Detail
-
getChildren
List<String> getChildren(String nodeId, int offset, int limit)
Retrieve the children of the specified node.- Parameters:
nodeId- the node idoffset- the offset within the list of child nodeslimit- the number of child nodes to return- Returns:
- a part of the child nodes of the specified node
-
getChildCount
int getChildCount(String nodeId)
Retrieve the number of children of the specified node.- Parameters:
nodeId- the node id- Returns:
- the number of child nodes
-
getParent
String getParent(String nodeId)
Retrieve the parent of the specified node.- Parameters:
nodeId- the node id- Returns:
- the parent node id
-
-