Module gen.tree

Class BaseTreeNode<V,​K>

  • Type Parameters:
    V - the generic type of the value
    K - the generic type of the id from the node
    All Implemented Interfaces:
    io.github.astrapi69.data.identifiable.GenericIdentifiable<K>, io.github.astrapi69.design.pattern.visitor.Acceptable<io.github.astrapi69.design.pattern.visitor.Visitor<BaseTreeNode<V,​K>>>, IBaseTreeNode<V,​K,​BaseTreeNode<V,​K>>, ITreeNode<V,​BaseTreeNode<V,​K>>, io.github.astrapi69.tree.api.ITree<V,​BaseTreeNode<V,​K>>, java.io.Serializable

    public class BaseTreeNode<V,​K>
    extends java.lang.Object
    implements IBaseTreeNode<V,​K,​BaseTreeNode<V,​K>>
    The generic class BaseTreeNode have a generic id and value object
    See Also:
    Serialized Form
    • Constructor Detail

      • BaseTreeNode

        public BaseTreeNode​(V value)
        Instantiates a new BaseTreeNode object
        Parameters:
        value - the value
    • Method Detail

      • getChildren

        public java.util.Collection<BaseTreeNode<V,​K>> getChildren()
        Gets the children of this node
        Specified by:
        getChildren in interface io.github.astrapi69.tree.api.ITree<V,​K>
        Returns:
        the children