Class InvisibleNode

    • Constructor Detail

      • InvisibleNode

        public InvisibleNode()
        Constructor
      • InvisibleNode

        public InvisibleNode​(Object userObject)
        Constructor for a new node that allows children and is visible
        Parameters:
        userObject - the user object to wrap at the node
      • InvisibleNode

        public InvisibleNode​(Object userObject,
                             boolean allowsChildren,
                             boolean isVisible)
        Constructor
        Parameters:
        userObject - the user object to wrap at the node
        allowsChildren - true if this node allows children (not a leaf)
        isVisible - true if this node is visible initially
    • Method Detail

      • getChildAt

        public TreeNode getChildAt​(int index,
                                   boolean filterIsActive)
        Get a child node
        Parameters:
        index - the index of the node to get
        filterIsActive - true if the visible filter is active
        Returns:
        a child node
      • getChildCount

        public int getChildCount​(boolean filterIsActive)
        Get the number of children nodes
        Parameters:
        filterIsActive - true if the visible filter is active (alters the count according to visibility)
        Returns:
        the number of child nodes
      • setVisible

        public void setVisible​(boolean visible)
        Set the visible status of this node
        Parameters:
        visible - true if this node should be visible
      • isVisible

        public boolean isVisible()
        Returns true if this node is visible
        Returns:
        true if this node is visible