Interface Node

  • All Known Subinterfaces:
    Node.Root

    @NonExtendable
    public interface Node
    A node in the MiniMessage parse tree.

    This API is currently incomplete -- it will be expanded in future versions based on user interest.

    Since:
    4.10.0
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Interface Description
      static interface  Node.Root
      The root node of a parse.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      @NotNull java.util.List<? extends Node> children()
      Get children of this node.
      @Nullable Node parent()
      Get the parent of this node.
      @NotNull java.lang.String toString()
      Get a human-readable representation of this node and its descendants for debugging purposes.
    • Method Detail

      • toString

        @NotNull
        @NotNull java.lang.String toString()
        Get a human-readable representation of this node and its descendants for debugging purposes.
        Overrides:
        toString in class java.lang.Object
        Returns:
        the human-readable representation of this node tree
        Since:
        4.10.0
      • children

        @NotNull
        @NotNull java.util.List<? extends Node> children()
        Get children of this node.

        The returned list is unmodifiable.

        Returns:
        a list of children
        Since:
        4.10.0
      • parent

        @Nullable
        @Nullable Node parent()
        Get the parent of this node.

        If this node is at the root of the tree, this may be null.

        Returns:
        this node's parent
        Since:
        4.10.0