de.matthiasmann.twl
Interface ParameterList

All Known Implementing Classes:
ParameterListImpl

public interface ParameterList


Method Summary
 Font getFont(int idx)
          Returns the font at the given list index.
 Image getImage(int idx)
          Returns the image at the given list index.
 MouseCursor getMouseCursor(int idx)
          Returns the mouse cursor at the given list index.
 boolean getParameter(int idx, boolean defaultValue)
           
 Color getParameter(int idx, Color defaultValue)
           
<E extends java.lang.Enum<E>>
E
getParameter(int idx, E defaultValue)
           
 float getParameter(int idx, float defaultValue)
           
 int getParameter(int idx, int defaultValue)
           
 java.lang.String getParameter(int idx, java.lang.String defaultValue)
           
 ParameterList getParameterList(int idx)
          Returns a parameter list at the given list index.
 ParameterMap getParameterMap(int idx)
          Returns a parameter map at the given list index.
 java.lang.Object getParameterValue(int idx)
          Retrives a parameter.
<T> T
getParameterValue(int idx, java.lang.Class<T> clazz)
          Retrieves a parameter and ensures that it has the desired type.
 int getSize()
           
 

Method Detail

getSize

int getSize()

getFont

Font getFont(int idx)
Returns the font at the given list index. If no font with that name was found then the default font is returned.

Parameters:
idx - The index in the list
Returns:
A font object

getImage

Image getImage(int idx)
Returns the image at the given list index. If no image with that name was found then null is returned.

Parameters:
idx - The index in the list
Returns:
A image object or null.

getMouseCursor

MouseCursor getMouseCursor(int idx)
Returns the mouse cursor at the given list index. If no mouse cursor with that name was found then null is returned.

Parameters:
idx - The index in the list
Returns:
A mouse cursor object or null.

getParameterMap

ParameterMap getParameterMap(int idx)
Returns a parameter map at the given list index. If no parameter map with that name was found then an empty map is returned.

Parameters:
idx - The index in the list
Returns:
A parameter map object.

getParameterList

ParameterList getParameterList(int idx)
Returns a parameter list at the given list index. If no parameter map with that name was found then an empty list is returned.

Parameters:
idx - The index in the list
Returns:
A parameter list object.

getParameter

boolean getParameter(int idx,
                     boolean defaultValue)

getParameter

int getParameter(int idx,
                 int defaultValue)

getParameter

float getParameter(int idx,
                   float defaultValue)

getParameter

java.lang.String getParameter(int idx,
                              java.lang.String defaultValue)

getParameter

Color getParameter(int idx,
                   Color defaultValue)

getParameter

<E extends java.lang.Enum<E>> E getParameter(int idx,
                                             E defaultValue)

getParameterValue

java.lang.Object getParameterValue(int idx)
Retrives a parameter.

Parameters:
idx - The index in the list
Returns:
the parameter value

getParameterValue

<T> T getParameterValue(int idx,
                        java.lang.Class<T> clazz)
Retrieves a parameter and ensures that it has the desired type.

Type Parameters:
T - The desired return type generic
Parameters:
idx - The index in the list
clazz - the required data type
Returns:
the parameter value or null if the type does not match