TV-Browser 3.3.3 API

util.paramhandler
Class ParamLibrary

java.lang.Object
  extended by util.paramhandler.ParamLibrary

public class ParamLibrary
extends java.lang.Object

The default ParamLibrary. If you want to add new parameters or functions for your plugin, extend this class and override the public methods. For an example see the code in the CapturePlugin

Author:
bodum

Constructor Summary
ParamLibrary()
           
 
Method Summary
 java.lang.String getDescriptionForFunctions(java.lang.String function)
          Get the description for a specific Function
 java.lang.String getDescriptionForKey(java.lang.String key)
          Get the description for one Key
 java.lang.String getErrorString()
          Returns the Error, empty if none occurred
 java.lang.String[] getPossibleFunctions()
          Get the List of possible Functions
 java.lang.String[] getPossibleKeys()
          Get the possible Keys
 java.lang.String getStringForFunction(Program prg, java.lang.String function, java.lang.String[] params)
          Returns the Value of a function
 java.lang.String getStringForKey(Program program, java.lang.String key)
          Get the String for a key
 boolean hasErrors()
          Has an Error occurred ?
 void setErrors(boolean errors)
          Set the Error-Boolean
 void setErrorString(java.lang.String error)
          Set the Error
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ParamLibrary

public ParamLibrary()
Method Detail

hasErrors

public boolean hasErrors()
Has an Error occurred ?

Returns:
true if an error occurred

setErrors

public void setErrors(boolean errors)
Set the Error-Boolean

Parameters:
errors - True, if an error occurred

getErrorString

public java.lang.String getErrorString()
Returns the Error, empty if none occurred

Returns:
error message

setErrorString

public void setErrorString(java.lang.String error)
Set the Error

Parameters:
error - the Error

getPossibleKeys

public java.lang.String[] getPossibleKeys()
Get the possible Keys

Returns:
Array with possible Keys

getDescriptionForKey

public java.lang.String getDescriptionForKey(java.lang.String key)
Get the description for one Key

Parameters:
key -
Returns:
description for one key

getPossibleFunctions

public java.lang.String[] getPossibleFunctions()
Get the List of possible Functions

Returns:
List of possible Functions

getDescriptionForFunctions

public java.lang.String getDescriptionForFunctions(java.lang.String function)
Get the description for a specific Function

Parameters:
function - parameter function
Returns:
localized description string

getStringForKey

public java.lang.String getStringForKey(Program program,
                                        java.lang.String key)
Get the String for a key

Parameters:
program - Program to use
key - Key to use
Returns:
Value of key in program

getStringForFunction

public java.lang.String getStringForFunction(Program prg,
                                             java.lang.String function,
                                             java.lang.String[] params)
Returns the Value of a function

Parameters:
prg - Program to use
function - Function to use
params - Params for the Function
Returns:
Return-Value of Function

TV-Browser 3.3.3 API

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