Package ninja.leaping.configurate.util
Class ConfigurationNodeWalker
java.lang.Object
ninja.leaping.configurate.util.ConfigurationNodeWalker
@Deprecated public abstract class ConfigurationNodeWalker extends Object
Deprecated.
Use ScopedConfigurationNode#visit(ConfigurationVisitor) instead
Represents a method for "walking" or traversing a
configuration
structure.-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
ConfigurationNodeWalker.VisitedNode<T extends ConfigurationNode>
Deprecated.Encapsulates a givennode
visited during a traversal. -
Field Summary
Fields Modifier and Type Field Description static ConfigurationNodeWalker
BREADTH_FIRST
Deprecated.AConfigurationNodeWalker
that implements a breadth-first traversal over the configuration.static ConfigurationNodeWalker
DEPTH_FIRST_POST_ORDER
Deprecated.AConfigurationNodeWalker
that implements a depth-first post-order traversal over the configuration.static ConfigurationNodeWalker
DEPTH_FIRST_PRE_ORDER
Deprecated.AConfigurationNodeWalker
that implements a depth-first pre-order traversal over the configuration. -
Constructor Summary
Constructors Constructor Description ConfigurationNodeWalker()
Deprecated. -
Method Summary
Modifier and Type Method Description <T extends ConfigurationNode>
@NonNull Iterator<T>walk(@NonNull T start)
Deprecated.Returns an iterator which will iterate over all nodes in the configuration, in the order defined by the walker.<T extends ConfigurationNode>
voidwalk(@NonNull T start, @NonNull BiConsumer<? super NodePath,? super T> consumer)
Deprecated.Walks the configuration, and calls theconsumer
for each path and node visited, in the order defined by the walker.abstract <T extends ConfigurationNode>
@NonNull Iterator<ConfigurationNodeWalker.VisitedNode<T>>walkWithPath(@NonNull T start)
Deprecated.Returns an iterator which will iterate over all paths and nodes in the configuration, in the order defined by the walker.
-
Field Details
-
BREADTH_FIRST
Deprecated.AConfigurationNodeWalker
that implements a breadth-first traversal over the configuration.See here for more info.
-
DEPTH_FIRST_PRE_ORDER
Deprecated.AConfigurationNodeWalker
that implements a depth-first pre-order traversal over the configuration.See here for more info.
-
DEPTH_FIRST_POST_ORDER
Deprecated.AConfigurationNodeWalker
that implements a depth-first post-order traversal over the configuration.See here for more info.
-
-
Constructor Details
-
ConfigurationNodeWalker
public ConfigurationNodeWalker()Deprecated.
-
-
Method Details
-
walkWithPath
public abstract <T extends ConfigurationNode> @NonNull Iterator<ConfigurationNodeWalker.VisitedNode<T>> walkWithPath(@NonNull T start)Deprecated.Returns an iterator which will iterate over all paths and nodes in the configuration, in the order defined by the walker.- Type Parameters:
T
- The node type- Parameters:
start
- The node to start at- Returns:
- An iterator of
ConfigurationNodeWalker.VisitedNode
s
-
walk
Deprecated.Returns an iterator which will iterate over all nodes in the configuration, in the order defined by the walker.- Type Parameters:
T
- The node type- Parameters:
start
- The node to start at- Returns:
- An iterator of
ConfigurationNode
s
-
walk
public <T extends ConfigurationNode> void walk(@NonNull T start, @NonNull BiConsumer<? super NodePath,? super T> consumer)Deprecated.Walks the configuration, and calls theconsumer
for each path and node visited, in the order defined by the walker.- Type Parameters:
T
- The node type- Parameters:
start
- The node to start atconsumer
- The consumer to accept the visited nodes
-