public interface Node extends NodeLike, TreeItem
ConfigNode| Modifier and Type | Method and Description |
|---|---|
java.util.Collection<TreeItem> |
getItems()
Returns a collection of this node's children.
|
java.lang.String |
getName()
Returns this node's name.
|
default boolean |
isSerializedSeparately()
Returns
true if this node should be serialized separately to its parent. |
TreeItem |
lookup(java.lang.String name)
Tries to find a child in this node by name.
|
@Nullable java.lang.String getName()
If this node is the root of a config tree, it may not have a name.
In this case, this method returns null.
@Nullable TreeItem lookup(java.lang.String name)
The value returned for a given name is always the same.
@Nonnull java.util.Collection<TreeItem> getItems()
The returned collection is unmodifiable, and guaranteed not to have two nodes with the same name.
default boolean isSerializedSeparately()
true if this node should be serialized separately to its parent.
If a node is serialized separately, it should not appear in the serialized representation of its parent. This setting has no effect if this node is a root.
true if this node should be serialized separately, and false otherwise