Module gen.tree

Class BaseMergeTreeNodesVisitor<V,K,T extends IBaseTreeNode<V,K,T>>

java.lang.Object
io.github.astrapi69.gen.tree.visitor.BaseMergeTreeNodesVisitor<V,K,T>
Type Parameters:
T - the generic type of the value
K - the generic type of the id of the node
All Implemented Interfaces:
io.github.astrapi69.design.pattern.visitor.Visitor<T>
Direct Known Subclasses:
MergeTreeNodesVisitor

public class BaseMergeTreeNodesVisitor<V,K,T extends IBaseTreeNode<V,K,T>> extends Object implements io.github.astrapi69.design.pattern.visitor.Visitor<T>
This visitor visits all IBaseTreeNode objects and merges all nodes to the given IBaseTreeNode object. This means only the given IBaseTreeNode object will be changed and the IBaseTreeNode object that implements this visitor will be not changed
  • Constructor Details

  • Method Details

    • visit

      public void visit(T treeNode)
      Specified by:
      visit in interface io.github.astrapi69.design.pattern.visitor.Visitor<V>