Class ASTTreeItem

  • All Implemented Interfaces:
    javafx.event.EventTarget

    public final class ASTTreeItem
    extends SearchableTreeView.SearchableTreeItem<net.sourceforge.pmd.lang.ast.Node>
    Represents a tree item (data, not UI) in the ast TreeView.
    Since:
    6.0.0
    Author:
    Clément Fournier
    • Nested Class Summary

      • Nested classes/interfaces inherited from class javafx.scene.control.TreeItem

        javafx.scene.control.TreeItem.TreeModificationEvent<T extends java.lang.Object>
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      ASTTreeItem findItem​(net.sourceforge.pmd.lang.ast.Node node)
      Finds the tree item corresponding to the given node among the descendants of this item.
      static <T,​N extends javafx.scene.control.TreeItem<T>>
      void
      foreach​(N root, java.util.function.Consumer<? super N> fun)  
      java.lang.String getSearchableText()  
      void setStyleClasses​(java.lang.String... classes)  
      void setStyleClasses​(java.util.Collection<java.lang.String> classes)  
      • Methods inherited from class javafx.scene.control.TreeItem

        addEventHandler, branchCollapsedEvent, branchExpandedEvent, buildEventDispatchChain, childrenModificationEvent, expandedItemCountChangeEvent, expandedProperty, getChildren, getGraphic, getParent, getValue, graphicChangedEvent, graphicProperty, isExpanded, isLeaf, leafProperty, nextSibling, nextSibling, parentProperty, previousSibling, previousSibling, removeEventHandler, setExpanded, setGraphic, setValue, toString, treeNotificationEvent, valueChangedEvent, valueProperty
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Method Detail

      • findItem

        public ASTTreeItem findItem​(net.sourceforge.pmd.lang.ast.Node node)
        Finds the tree item corresponding to the given node among the descendants of this item. This method assumes this item is the root node.
        Parameters:
        node - The node to find
        Returns:
        The found item, or null if this item doesn't wrap the root of the tree to which the parameter belongs
      • setStyleClasses

        public void setStyleClasses​(java.util.Collection<java.lang.String> classes)
      • setStyleClasses

        public void setStyleClasses​(java.lang.String... classes)
      • foreach

        public static <T,​N extends javafx.scene.control.TreeItem<T>> void foreach​(N root,
                                                                                        java.util.function.Consumer<? super N> fun)