public interface HierarchyNodeReader
| Modifier and Type | Method and Description |
|---|---|
Set<HierarchyNode> |
getChildNodes(String nodeId,
boolean directOnly)
Get all children nodes for this node in the hierarchy all the way to the leaves,
will return no nodes if this node has no children
|
HierarchyNode |
getNodeById(String nodeId)
Get a node based on the unique id,
convenience method for
getNodesByIds(String[]) |
Map<String,HierarchyNode> |
getNodesByIds(String[] nodeIds)
Get a set of nodes based on their unique ids,
NOTE: this method is here for efficiency
|
Set<HierarchyNode> |
getParentNodes(String nodeId,
boolean directOnly)
Get all the parent nodes for a specific node all the way to the root node,
returns empty set if this is the root node
|
HierarchyNode |
getRootNode(String hierarchyId)
Get the hierarchy root node for a specific hierarchy if it exists
|
HierarchyNode getRootNode(String hierarchyId)
hierarchyId - a unique string which identifies this hierarchyHierarchyNode representing the root of the hierarchy
if found, otherwise returns a nullHierarchyNode getNodeById(String nodeId)
getNodesByIds(String[])nodeId - a unique id for a hierarchy nodeHierarchyNode representing this node or null if it does not existMap<String,HierarchyNode> getNodesByIds(String[] nodeIds)
nodeIds - unique ids for hierarchy nodesHierarchyNodeSet<HierarchyNode> getParentNodes(String nodeId, boolean directOnly)
nodeId - a unique id for a hierarchy nodedirectOnly - if true then only include the nodes which are directly connected to this node,
else return every node that is a parent of this nodeHierarchyNode objects representing all parent nodes for the specified child,
empty set if no parents foundSet<HierarchyNode> getChildNodes(String nodeId, boolean directOnly)
nodeId - a unique id for a hierarchy nodedirectOnly - if true then only include the nodes which are directly connected to this node,
else return every node that is a child of this nodeHierarchyNode objects representing all children nodes for the specified parent,
empty set if no children foundCopyright © 2003–2021 Sakai Project. All rights reserved.