Package docking.widgets.table.columnfilter

# Class ColumnFilterSaveManager<R>

java.lang.Object
docking.widgets.table.columnfilter.ColumnFilterSaveManager<R>

Type Parameters:
  `R` - the row type of the table.

public class ColumnFilterSaveManager<R> extends Object
Loads and Save a list of ColumnTableFilters for a specific table to the tool

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ColumnFilterSaveManager(GTableFilterPanel<R> panel, JTable table, RowObjectTableModel<R> model, Object dataSource)`
  Constructor

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `addFilter(ColumnBasedTableFilter<R> filter)`
  Adds a new ColumnTableFilter to be saved.
  `boolean`
  `containsFilterWithName(String name)`
  Returns true if this save manager contains any filters with the given name.
  `List<ColumnBasedTableFilter<R>>`
  `getSavedFilters()`
  Returns a list of the saved ColumnTableFilters
  `void`
  `removeFilter(ColumnBasedTableFilter<R> filter)`
  Deletes a ColumnTableFilter from the list of saved filters.
  `void`
  `save()`
  Saves the list of filters to the tool's preference state.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### ColumnFilterSaveManager

    public ColumnFilterSaveManager(GTableFilterPanel<R> panel, JTable table, RowObjectTableModel<R> model, Object dataSource)
    Constructor
    Parameters:
      `panel` - The GTableFilterPanel for the table.
      `table` - The JTable that is filterable.
      `model` - the TableModel that supports filtering.
      `dataSource` - the table's DataSource object.

- ## Method Details

  - ### addFilter

    public void addFilter(ColumnBasedTableFilter<R> filter)
    Adds a new ColumnTableFilter to be saved.
    Parameters:
      `filter` - The filter to be saved.

  - ### removeFilter

    public void removeFilter(ColumnBasedTableFilter<R> filter)
    Deletes a ColumnTableFilter from the list of saved filters.
    Parameters:
      `filter` - the filter to remove from the list of saved filters.

  - ### save

    public void save()
    Saves the list of filters to the tool's preference state.

  - ### getSavedFilters

    public List<ColumnBasedTableFilter<R>> getSavedFilters()
    Returns a list of the saved ColumnTableFilters
    Returns:
      a list of the saved ColumnTableFilters

  - ### containsFilterWithName

    public boolean containsFilterWithName(String name)
    Returns true if this save manager contains any filters with the given name.
    Parameters:
      `name` - the name to check for a filter's existence.
    Returns:
      true if this save manager contains any filters with the given name.