TV-Browser 2.7.5 API

imdbplugin
Class ImdbPlugin

java.lang.Object
  extended by devplugin.Plugin
      extended by imdbplugin.ImdbPlugin
All Implemented Interfaces:
ContextMenuIf, Marker, ProgramReceiveIf

public class ImdbPlugin
extends Plugin


Field Summary
 
Fields inherited from class devplugin.Plugin
BIG_ICON, DISABLED_ON_TASK_MENU, parent, SINGLE_CLICK_WAITING_TIME
 
Constructor Summary
ImdbPlugin()
           
 
Method Summary
 ActionMenu getContextMenuActions(Program program)
          Gets the actions for the context menu of a program.
 Channel[] getExcludedChannels()
           
 PluginInfo getInfo()
          Gets the meta information about the plugin.
 Icon[] getProgramTableIcons(Program program)
          Gets the icons this Plugin provides for the given program.
 String getProgramTableIconText()
          Gets the description text for the program table icons provided by this Plugin.
 ProgramRatingIf[] getRatingInterfaces()
          If this plugin can rate programs, this interface makes it possible to offer this ratings to other plugins.
 SettingsTab getSettingsTab()
          Gets the SettingsTab object, which is added to the settings-window.
static Version getVersion()
           
 void handleTvBrowserStartFinished()
          This method is called when the TV-Browser start is finished.
 void loadSettings(Properties settings)
          Called by the host-application during start-up.
 void readData(ObjectInputStream in)
          Called by the host-application during start-up.
 void setExcludedChannels(Channel[] excludedChannels)
           
 void showUpdateDialog()
           
 Properties storeSettings()
          Called by the host-application during shut-down.
 void updateCurrentDateAndClearCache()
          Force an update of the currently shown programs in the program table where we need to add/update a rating.
 void writeData(ObjectOutputStream out)
          Counterpart to loadData.
 
Methods inherited from class devplugin.Plugin
canReceivePrograms, canReceiveProgramsWithTarget, canUseProgramTree, createImageIcon, createImageIcon, createImageIcon, createImageIconForFileName, execute, execute, execute, getAvailableFilter, getAvailableFilterComponentClasses, getButtonAction, getButtonIconName, getButtonText, getContextMenuItemText, getId, getJarFile, getMarkIcon, getMarkIconFromTheme, getMarkIconName, getMarkIcons, getMarkIconsForProgram, getMarkPriorityForProgram, getParentFrame, getPluginManager, getProgramFromContextMenuActionEvent, getProgramReceiveTargets, getRootNode, handleTvDataAdded, handleTvDataAdded, handleTvDataChanged, handleTvDataChanged, handleTvDataDeleted, handleTvDataTouched, handleTvDataUpdateFinished, isAllowedToDeleteProgramFilter, layoutWindow, layoutWindow, onActivation, onDeactivation, receivePrograms, receivePrograms, receiveValues, saveMe, setJarFile, setParent, setPluginManager, storeRootNode, supportMultipleProgramExecution, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ImdbPlugin

public ImdbPlugin()
Method Detail

getInfo

public PluginInfo getInfo()
Description copied from class: Plugin
Gets the meta information about the plugin.

Override this method to provide information about your plugin.

Overrides:
getInfo in class Plugin
Returns:
The meta information about the plugin.

getVersion

public static Version getVersion()

getProgramTableIcons

public Icon[] getProgramTableIcons(Program program)
Description copied from class: Plugin
Gets the icons this Plugin provides for the given program. These icons will be shown in the program table under the start time.

Override this method to return the icons for the program table (shown below the start time).

This method is only called, if the option to show program table icons for this plugin is set in the options.

Overrides:
getProgramTableIcons in class Plugin
Parameters:
program - The programs to get the icons for.
Returns:
The icons for the given program or null if the plugin does not provide this feature.
See Also:
Plugin.getProgramTableIconText()

getContextMenuActions

public ActionMenu getContextMenuActions(Program program)
Description copied from class: Plugin
Gets the actions for the context menu of a program.

Override this method to provide context menu items for programs (e.g. in the program table). If your plugin shows a context menu only for some programs, but not for all, then you should explicitly return a non-null menu for the example program. Otherwise your context menu will not be shown in the settings dialog for the context menu order.

The following action values will be used:

Specified by:
getContextMenuActions in interface ContextMenuIf
Overrides:
getContextMenuActions in class Plugin
Parameters:
program - The program the context menu will be shown for.
Returns:
the actions this plugin provides for the given program or null if the plugin does not provide this feature.
See Also:
Plugin.getProgramFromContextMenuActionEvent(ActionEvent)

getProgramTableIconText

public String getProgramTableIconText()
Description copied from class: Plugin
Gets the description text for the program table icons provided by this Plugin.

Override this method if your plugin provides icons for the program table (shown below the start time). The returned String will be shown in settings dialog (german: Aussehen->Sendungsanzeige->Plugin-Icons).

Overrides:
getProgramTableIconText in class Plugin
Returns:
The description text for the program table icons or null if the plugin does not provide this feature.
See Also:
Plugin.getProgramTableIcons(Program)

handleTvBrowserStartFinished

public void handleTvBrowserStartFinished()
Description copied from class: Plugin
This method is called when the TV-Browser start is finished.

Overrides:
handleTvBrowserStartFinished in class Plugin

showUpdateDialog

public void showUpdateDialog()

loadSettings

public void loadSettings(Properties settings)
Description copied from class: Plugin
Called by the host-application during start-up.

Override this method to load your plugins settings from the file system.

Overrides:
loadSettings in class Plugin
Parameters:
settings - The settings for this plugin (May be empty).

storeSettings

public Properties storeSettings()
Description copied from class: Plugin
Called by the host-application during shut-down.

Override this method to store your plugins settings to the file system. ATTENTION: Don't use any logger, thread or access to Frames in this method.

Overrides:
storeSettings in class Plugin
Returns:
The settings for this plugin or null if this plugin does not need to save any settings.

readData

public void readData(ObjectInputStream in)
              throws IOException,
                     ClassNotFoundException
Description copied from class: Plugin
Called by the host-application during start-up.

Override this method to load any objects from the file system.

Overrides:
readData in class Plugin
Parameters:
in - The stream to read the objects from.
Throws:
IOException - If reading failed.
ClassNotFoundException - If an object could not be casted correctly.
See Also:
Plugin.writeData(ObjectOutputStream)

writeData

public void writeData(ObjectOutputStream out)
               throws IOException
Description copied from class: Plugin
Counterpart to loadData. Called when the application shuts down.

Override this method to store any objects to the file system. ATTENTION: Don't use any logger, thread or access to Frames in this method.

Overrides:
writeData in class Plugin
Parameters:
out - The stream to write the objects to
Throws:
IOException - If writing failed.
See Also:
Plugin.readData(ObjectInputStream)

getSettingsTab

public SettingsTab getSettingsTab()
Description copied from class: Plugin
Gets the SettingsTab object, which is added to the settings-window.

Override this method to provide a settings tab. The settings tab will be shown in the settings dialog in the plugin section.

Overrides:
getSettingsTab in class Plugin
Returns:
the SettingsTab object or null if the plugin does not provide this feature.

updateCurrentDateAndClearCache

public void updateCurrentDateAndClearCache()
Force an update of the currently shown programs in the program table where we need to add/update a rating. Internally called after a successful update of the imdb ratings database.


getExcludedChannels

public Channel[] getExcludedChannels()

setExcludedChannels

public void setExcludedChannels(Channel[] excludedChannels)

getRatingInterfaces

public ProgramRatingIf[] getRatingInterfaces()
Description copied from class: Plugin
If this plugin can rate programs, this interface makes it possible to offer this ratings to other plugins. You can get all ProgramRatingIfs of all plugins using PluginManager.getAllProgramRatingIfs() The plugin can return more than one ratingif, e.g. average ratings, user rating ...

Overrides:
getRatingInterfaces in class Plugin
Returns:
the RatingIfs of this plugin

TV-Browser 2.7.5 API

TV-Browser 2.7.5, Copyright (C) 04-2003 Martin Oberhauser (martin@tvbrowser.org)