devplugin

## Interface FilterManager

- All Known Implementing Classes:
    FilterManagerImpl

      public interface FilterManager

  The filter manager enables plugins to use the filter system of TV-Browser.
  Since:
    2.5
  Author:
    René Mach

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `addFilter(PluginsProgramFilter filter)`
    `java.lang.String` | `addNewChannelFilterComponent()` Opens a dialog to create new channel filter components.
    `boolean` | `deleteFilter(PluginsProgramFilter filter)`
    `ProgramFilter` | `getAllFilter()` Gets the "ShowAll" filter of the program table.
    `ChannelFilter[]` | `getAvailableChannelFilters()` Gets the available channel filters.
    `ProgramFilter[]` | `getAvailableFilters()` Returns an array of all available filters.
    `java.lang.String[]` | `getChannelFilterComponentNames()` Gets the names of the channel filter components.
    `ChannelFilter` | `getCurrentChannelFilter()` Gets the current channel filter.
    `ProgramFilter` | `getCurrentFilter()` Returns the current selected filter of the program table.
    `ProgramFilter` | `getDefaultFilter()` Returns the default filter of the program table.
    `boolean` | `isPluginFilter(ProgramFilter filter)` Tests if the filter is a plugin filter.
    `void` | `registerChannelFilterChangeListener(ChannelFilterChangeListener listener)` Registers the given ChannelFilterChangeListener.
    `void` | `registerFilterChangeListener(FilterChangeListener listener)` Deprecated. since 3.3.4 use `registerFilterChangeListener(FilterChangeListenerV2)` instead.
    `void` | `registerFilterChangeListener(FilterChangeListenerV2 listener)` Registers the given FilterChangeListener.
    `void` | `setChannelFilter(ChannelFilter filter)` Sets the current channel filter.
    `void` | `setCurrentFilter(ProgramFilter filter)` Activates a filter.
    `void` | `unregisterChannelFilterChangeListener(ChannelFilterChangeListener listener)` Unregisters the given ChannelFilterChangeListener.
    `void` | `unregisterFilterChangeListener(FilterChangeListener listener)` Deprecated. since 3.3.4 use `unregisterFilterChangeListener(FilterChangeListenerV2)` instead.
    `void` | `unregisterFilterChangeListener(FilterChangeListenerV2 listener)` Unregisters the given FilterChangeListener.

- - ### Method Detail

    - #### getCurrentFilter

          ProgramFilter getCurrentFilter()

      Returns the current selected filter of the program table.
      Returns:
        The current selected filter of the program table.

    - #### getDefaultFilter

          ProgramFilter getDefaultFilter()

      Returns the default filter of the program table.
      Returns:
        The default filter of the program table.

    - #### getAllFilter

          ProgramFilter getAllFilter()

      Gets the "ShowAll" filter of the program table.
      Returns:
        The "ShowAll" filter of the program table.

    - #### setCurrentFilter

          void setCurrentFilter(ProgramFilter filter)

      Activates a filter.
      Parameters:
        `filter` - The filter to activate.

    - #### getAvailableFilters

          ProgramFilter[] getAvailableFilters()

      Returns an array of all available filters.
      Returns:
        An array of all available filters.

    - #### addFilter

          boolean addFilter(PluginsProgramFilter filter)

      Parameters:
        `filter` - The filter to add.
      Returns:
        True if the filter could be added.

    - #### deleteFilter

          boolean deleteFilter(PluginsProgramFilter filter)

      Parameters:
        `filter` - The filter to delete.
      Returns:
        True if the filter could be deleted.

    - #### isPluginFilter

          boolean isPluginFilter(ProgramFilter filter)

      Tests if the filter is a plugin filter.
      Parameters:
        `filter` - The filter to test.
      Returns:
        `True` if the filter is a plugin filter, `false` otherwise.
      Since:
        2.6

    - #### getChannelFilterComponentNames

          java.lang.String[] getChannelFilterComponentNames()

      Gets the names of the channel filter components.

      Returns:
        The names of the channel filter components.
      Since:
        3.2.1

    - #### addNewChannelFilterComponent

          java.lang.String addNewChannelFilterComponent()

      Opens a dialog to create new channel filter components.

      Returns:
        The name of the created filter component, or `null` if no component was created.
      Since:
        3.2.1

    - #### registerFilterChangeListener

          void registerFilterChangeListener(FilterChangeListener listener)

      Deprecated. since 3.3.4 use `registerFilterChangeListener(FilterChangeListenerV2)` instead.
      Registers the given FilterChangeListener.

      Parameters:
        `listener` - The listener to register.
      Since:
        3.3.3

    - #### registerFilterChangeListener

          void registerFilterChangeListener(FilterChangeListenerV2 listener)

      Registers the given FilterChangeListener.

      Parameters:
        `listener` - The listener to register.
      Since:
        3.3.4

    - #### unregisterFilterChangeListener

          void unregisterFilterChangeListener(FilterChangeListener listener)

      Deprecated. since 3.3.4 use `unregisterFilterChangeListener(FilterChangeListenerV2)` instead.
      Unregisters the given FilterChangeListener.

      Parameters:
        `listener` - The listener to remove.
      Since:
        3.3.3

    - #### unregisterFilterChangeListener

          void unregisterFilterChangeListener(FilterChangeListenerV2 listener)

      Unregisters the given FilterChangeListener.

      Parameters:
        `listener` - The listener to remove.
      Since:
        3.3.4

    - #### getCurrentChannelFilter

          ChannelFilter getCurrentChannelFilter()

      Gets the current channel filter.

      Returns:
        The current channel filter or `null` if no channel filter is active.
      Since:
        3.4.1

    - #### setChannelFilter

          void setChannelFilter(ChannelFilter filter)

      Sets the current channel filter.

      Parameters:
        `filter` - The channel filter to set or `null` to disable current channel filter.
      Since:
        3.4.1

    - #### getAvailableChannelFilters

          ChannelFilter[] getAvailableChannelFilters()

      Gets the available channel filters.

      Returns:
        The available channel filters.
      Since:
        3.4.1

    - #### registerChannelFilterChangeListener

          void registerChannelFilterChangeListener(ChannelFilterChangeListener listener)

      Registers the given ChannelFilterChangeListener.

      Parameters:
        `listener` - The listener to register
      Since:
        3.4.1

    - #### unregisterChannelFilterChangeListener

          void unregisterChannelFilterChangeListener(ChannelFilterChangeListener listener)

      Unregisters the given ChannelFilterChangeListener.

      Parameters:
        `listener` - The listener to unregister.
      Since:
        3.4.1

TV-Browser 3.4.3, Copyright (C) 2004-2008 TV-Browser Team (dev@tvbrowser.org)