Class InheritanceGraph
java.lang.Object
me.lucko.luckperms.common.inheritance.InheritanceGraph
- All Implemented Interfaces:
Graph<PermissionHolder>
A
Graph which represents an "inheritance tree".-
Constructor Summary
ConstructorsConstructorDescriptionInheritanceGraph(LuckPermsPlugin plugin, net.luckperms.api.query.QueryOptions queryOptions) -
Method Summary
Modifier and TypeMethodDescriptionIterable<? extends PermissionHolder> successors(PermissionHolder holder) Returns all nodes in this graph directly adjacent tonodewhich can be reached by traversingnode's outgoing edges.traverse(TraversalAlgorithm algorithm, boolean postTraversalSort, PermissionHolder startNode) Returns an iterable which will traverse this inheritance graph using the specified algorithm starting at the given permission holder start node.traverse(PermissionHolder startNode) Perform a traversal according to the rules defined in the configuration.
-
Constructor Details
-
InheritanceGraph
-
-
Method Details
-
successors
Description copied from interface:GraphReturns all nodes in this graph directly adjacent tonodewhich can be reached by traversingnode's outgoing edges.- Specified by:
successorsin interfaceGraph<PermissionHolder>
-
traverse
public Iterable<PermissionHolder> traverse(TraversalAlgorithm algorithm, boolean postTraversalSort, PermissionHolder startNode) Returns an iterable which will traverse this inheritance graph using the specified algorithm starting at the given permission holder start node.- Parameters:
algorithm- the algorithm to use when traversingpostTraversalSort- if a final sort according to inheritance (weight, primary group) rules should be performed after the traversal algorithm has completedstartNode- the start node in the inheritance graph- Returns:
- an iterable
-
traverse
Perform a traversal according to the rules defined in the configuration.- Parameters:
startNode- the start node in the inheritance graph- Returns:
- an iterable
-