Class AbstractTreeTableOption

All Implemented Interfaces:
Serializable, ActionHolder, Option, OptionElement, OptionProperties
Direct Known Subclasses:
JobDataPanel, JVMHealthPanel, NodeDataPanel

public abstract class AbstractTreeTableOption extends AbstractOption implements ActionHolder
Abstract implementation of a tree table-based option.
Author:
Laurent Cohen
See Also:
  • Field Details

    • BASE

      protected String BASE
      Base name for localization bundle lookups.
    • model

      protected transient AbstractJPPFTreeTableModel model
      The tree table model associated with the tree table.
    • treeTableRoot

      protected DefaultMutableTreeNode treeTableRoot
      The root of the tree model.
    • treeTable

      protected JPPFTreeTable treeTable
      A tree table component displaying the driver and nodes information.
    • actionHandler

      protected JTreeTableActionHandler actionHandler
      Handles all actions in toolbars or popup menus.
  • Constructor Details

    • AbstractTreeTableOption

      public AbstractTreeTableOption()
  • Method Details

    • getActionHandler

      public JTreeTableActionHandler getActionHandler()
      Get the object that handles all actions in toolbars or popup menus.
      Specified by:
      getActionHandler in interface ActionHolder
      Returns:
      a JTreeTableActionHandler instance.
    • getTreeTable

      public JPPFTreeTable getTreeTable()
      Get the tree table component displaying the driver and nodes information.
      Returns:
      a JPPFTreeTable instance.
    • setEnabled

      public void setEnabled(boolean enabled)
      Not implemented.
      Specified by:
      setEnabled in interface OptionProperties
      Parameters:
      enabled - not used.
      See Also:
    • setEventsEnabled

      public void setEventsEnabled(boolean enabled)
      Not implemented.
      Specified by:
      setEventsEnabled in interface OptionProperties
      Overrides:
      setEventsEnabled in class AbstractOptionProperties
      Parameters:
      enabled - not used.
      See Also:
    • setupValueChangeNotifications

      protected void setupValueChangeNotifications()
      Not implemented.
      Specified by:
      setupValueChangeNotifications in class AbstractOption
      See Also:
    • localize

      protected String localize(String message)
      Get a localized message given its unique name and the current locale.
      Parameters:
      message - - the unique name of the localized message.
      Returns:
      a message in the current locale, or the default locale if the localization for the current locale is not found.
    • setupTableColumns

      public void setupTableColumns()
      Set the columns width based on values stored as preferences.
    • saveTableColumnsSettings

      public void saveTableColumnsSettings()
      Set the columns width based on values stored as preferences.
    • getTreeTableRoot

      public DefaultMutableTreeNode getTreeTableRoot()
      Get the root of the tree model.
      Returns:
      a DefaultMutableTreeNode instance.
    • getModel

      public AbstractJPPFTreeTableModel getModel()
      get the tree table model associated with the tree table.
      Returns:
      an AbstractJPPFTreeTableModel instance.
    • restoreColumns

      public void restoreColumns(Collection<Integer> positions)
      Restore the previously hidden columns with the specified positions in the tree table model.
      Parameters:
      positions - the positions of the columns position in the tree table model (not the table column model).
    • isColumnHidden

      public boolean isColumnHidden(int pos)
      Determine whether the column with the specified position in the tree table model is hidden.
      Parameters:
      pos - the column position in the tree table model (not the table column model).
      Returns:
      true if the column is hidden, false otherwise.
    • getVisibleColumnIndexes

      public List<Integer> getVisibleColumnIndexes()
      Returns:
      the positions of the visible table columns represented by their index in the tree table model.