Interface TreeCheckingModel

All Known Implementing Classes:
DefaultTreeCheckingModel, NullTreeCheckingModel

public interface TreeCheckingModel
The interface of a model for checking/unchecking the nodes of a CheckboxTree. Alterations of a node state may propagate to descendants/ancestors, according to the behaviour of the checking model. See CheckingMode for the available behaviours.
Author:
bigagli, boldrini
  • Method Details

    • addCheckingPath

      void addCheckingPath(TreePath path)
      add a path to the checking set.
      Parameters:
      path - the path to be added.
    • addCheckingPaths

      void addCheckingPaths(TreePath[] paths)
      add paths to the checking set.
      Parameters:
      paths - the paths to be added.
    • addTreeCheckingListener

      void addTreeCheckingListener(TreeCheckingListener tcl)
      Adds the specified listener to the list of those being notified upon changes in the the checking set.
      Parameters:
      tcl - the new listener to be added.
    • clearChecking

      void clearChecking()
      Clears the checking.
    • getCheckingMode

      Returns:
      Returns the CheckingMode.
    • getCheckingPaths

      TreePath[] getCheckingPaths()
      Returns:
      Returns the paths that are in the checking set.
    • getCheckingRoots

      TreePath[] getCheckingRoots()
      Returns:
      Returns the paths that are in the checking set and are the (upper) roots of checked trees.
    • getGreyingPaths

      TreePath[] getGreyingPaths()
      Returns:
      Returns the paths that are in the greying set.
    • isPathChecked

      boolean isPathChecked(TreePath path)
      Returns true if the item identified by the path is currently checked.
      Parameters:
      path - a TreePath identifying a node
      Returns:
      true if the node is checked
    • isPathEnabled

      boolean isPathEnabled(TreePath path)
      Returns whether the specified path checking state can be toggled.
    • isPathGreyed

      boolean isPathGreyed(TreePath path)
      Returns whether the specified path is greyed.
    • removeCheckingPath

      void removeCheckingPath(TreePath path)
      Removes a path from the checking set.
      Parameters:
      path - the path to be removed.
    • removeCheckingPaths

      void removeCheckingPaths(TreePath[] paths)
      Remove the specified paths from the checking set.
      Parameters:
      paths - the paths to be added.
    • removeTreeCheckingListener

      void removeTreeCheckingListener(TreeCheckingListener tcl)
      Removes the specified listener from the list of those being notified upon changes in the checking set.
      Parameters:
      tcl - the listener to remove.
    • setCheckingMode

      void setCheckingMode(TreeCheckingModel.CheckingMode mode)
      Sets the specified checking mode.
      Parameters:
      mode - the checking mode to set.
    • setCheckingPath

      void setCheckingPath(TreePath path)
      (Re)sets the checking to the specified path.
    • setCheckingPaths

      void setCheckingPaths(TreePath[] paths)
      (Re)sets the checking to the specified paths.
    • setPathEnabled

      void setPathEnabled(TreePath path, boolean enable)
      Sets whether or not the specified path can be toggled.
      Parameters:
      path - the path to enable/disable
    • setPathsEnabled

      void setPathsEnabled(TreePath[] paths, boolean enable)
      Sets whether or not the specified paths can be toggled.
      Parameters:
      paths - the paths to enable/disable
    • toggleCheckingPath

      void toggleCheckingPath(TreePath pathForRow)
      Toggles (check/uncheck) the checking state of the specified path, if this is enabled, and possibly propagate the change, according to the checking mode.