TV-Browser 3.3.3 API

devplugin
Class ChannelFilter

java.lang.Object
  extended by devplugin.ChannelFilter
All Implemented Interfaces:
ProgramFilter

public final class ChannelFilter
extends java.lang.Object
implements ProgramFilter

A filter that channels for filters using a ChannelFilterComponent. NOTE: The ChannelFilterComponent cannot be added itself, only the name of the of the ChannelFilterComponent can be provided to load it internal.

Since:
3.2.1
Author:
René Mach

Method Summary
 boolean accept(Program program)
           
static ChannelFilter createChannelFilterForName(java.lang.String name)
          Creates a channel filter with the name of the component to create the filter from.
 Channel[] getChannels()
          Gets all the channels of this channel filter.
 java.lang.String getName()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface devplugin.ProgramFilter
toString
 

Method Detail

createChannelFilterForName

public static ChannelFilter createChannelFilterForName(java.lang.String name)
                                                throws java.lang.ClassCastException,
                                                       TvBrowserException
Creates a channel filter with the name of the component to create the filter from.

Parameters:
name - The name of the filter component to create the channel filter from.
Returns:
The created channel filter.
Throws:
java.lang.ClassCastException - Thrown if the found component is not a ChannelFilterComponent.
TvBrowserException - Thrown if the ChannelFilterComponent with the given name was not found.

accept

public boolean accept(Program program)
Specified by:
accept in interface ProgramFilter
Parameters:
program - the program to be checked
Returns:
true, if the filter accepts the specified program

getName

public java.lang.String getName()
Specified by:
getName in interface ProgramFilter
Returns:
the name of this filter

getChannels

public Channel[] getChannels()
Gets all the channels of this channel filter.

Returns:
All channels of this channel filter.

TV-Browser 3.3.3 API

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