com.jbbres.lib.actions.elements
Interface ElementDescription<T extends Element>

All Superinterfaces:
java.lang.Comparable<ElementDescription<?>>, com.jbbres.lib.search.Searchable
All Known Subinterfaces:
ActionDescription, VariableDescription
All Known Implementing Classes:
AbstractElementDescription, DefaultActionDescription, DefaultVariableDescription, ResourceBundleActionDescription, ResourceBundleElementDescription, ResourceBundleVariableDescription, SimpleActionDescription, SimpleElementDescription, SimpleVariableDescription, VariableActionDescription

public interface ElementDescription<T extends Element>
extends com.jbbres.lib.search.Searchable, java.lang.Comparable<ElementDescription<?>>

Provides information regarding the element, such as its name, a short description, its version number etc.

Those information might or might not be the same as the one provided by the element information property list and have various usage within the workflow definition process, but one of the strength of the ElementDescription over the element information property list is that it can provide information specific to an instance of the element, where the element information property list only provide general information regarding the Element class.

Since:
1.0.0
Version:
1.0.0
Author:
Jean-Baptiste Bres
See Also:
Element.getDescription(), ActionDescription, VariableDescription

Field Summary
static java.lang.String CATEGORY_SEPARATOR
          The character used to separated categories in the description file: semicolumn (;)
static java.lang.String DESCRIPTION_CATEGORIES
          The categories that the element belongs too.
static java.lang.String DESCRIPTION_COMPANY_NAME
          The company that develops the element.
static java.lang.String DESCRIPTION_COMPANY_SUPPORT
          The support website.
static java.lang.String DESCRIPTION_COMPANY_WEBSITE
          The company website.
static java.lang.String DESCRIPTION_COPYRIGHT
          The copyright of the element.
static java.lang.String DESCRIPTION_ICON
          The icon ressource representing the element.
static java.lang.String DESCRIPTION_SUMMARY
          A summary of what the element is doing.
static java.lang.String DESCRIPTION_TITLE
          The title of the element.
static java.lang.String DESCRIPTION_VERSION
          The version of the element.
static java.lang.String TYPE
          The type of the element.
 
Method Summary
 void addElementDescriptionChangeListener(ElementDescriptionChangeListener listener)
          Adds a element description change listener.
 Category[] getCategories()
          Returns the categories associated to the element.
 java.lang.String getDescription(java.lang.String key)
          Returns the information associated to the given key.
 javax.swing.ImageIcon getIcon()
          Returns the icon associated to the element.
 Element newElementInstance(Workflow workflow)
          Creates and returns a new instance of the element described.
 void removeElementDescriptionChangeListener(ElementDescriptionChangeListener listener)
          Removes a element description change listener.
 
Methods inherited from interface com.jbbres.lib.search.Searchable
getSearchableValue
 
Methods inherited from interface java.lang.Comparable
compareTo
 

Field Detail

CATEGORY_SEPARATOR

static final java.lang.String CATEGORY_SEPARATOR
The character used to separated categories in the description file: semicolumn (;)

See Also:
Constant Field Values

TYPE

static final java.lang.String TYPE
The type of the element. Acceptable values associated to this key are "action" and "variable"

See Also:
Constant Field Values

DESCRIPTION_TITLE

static final java.lang.String DESCRIPTION_TITLE
The title of the element.

See Also:
Constant Field Values

DESCRIPTION_SUMMARY

static final java.lang.String DESCRIPTION_SUMMARY
A summary of what the element is doing.

See Also:
Constant Field Values

DESCRIPTION_COMPANY_NAME

static final java.lang.String DESCRIPTION_COMPANY_NAME
The company that develops the element. This data is stored but not used by Action(s) yet

See Also:
Constant Field Values

DESCRIPTION_COMPANY_WEBSITE

static final java.lang.String DESCRIPTION_COMPANY_WEBSITE
The company website. This data is stored but not used by Action(s) yet

See Also:
Constant Field Values

DESCRIPTION_COMPANY_SUPPORT

static final java.lang.String DESCRIPTION_COMPANY_SUPPORT
The support website. This data is stored but not used by Action(s) yet

See Also:
Constant Field Values

DESCRIPTION_VERSION

static final java.lang.String DESCRIPTION_VERSION
The version of the element.

See Also:
Constant Field Values

DESCRIPTION_COPYRIGHT

static final java.lang.String DESCRIPTION_COPYRIGHT
The copyright of the element.

See Also:
Constant Field Values

DESCRIPTION_ICON

static final java.lang.String DESCRIPTION_ICON
The icon ressource representing the element.

The value associated to this key should be a String giving the addresse of the image ressource. The address can be either relative from the properties file, either absolute.
If the name begins with a '/' ('/'), then the absolute name of the resource is the portion of the name following the '/'. Otherwise, the absolute name is of the following form:

modified_package_name/name
Where the modified_package_name is the package name of this object with '/' substituted for '.' ('.').

See Also:
Constant Field Values

DESCRIPTION_CATEGORIES

static final java.lang.String DESCRIPTION_CATEGORIES
The categories that the element belongs too. Each category should be separated by a semicolumn (;)

See Also:
Constant Field Values
Method Detail

newElementInstance

Element newElementInstance(Workflow workflow)
Creates and returns a new instance of the element described.

This methods should not add the new element to the given workflow. Action(s) takes care of calling the appropried Workflow.add(Element) method.

Parameters:
workflow - - the workflow that will own the element
Returns:
a new instance of the element described.

getDescription

java.lang.String getDescription(java.lang.String key)
Returns the information associated to the given key.

Parameters:
key - - the key
Returns:
the information associated to the given key.

getIcon

javax.swing.ImageIcon getIcon()
Returns the icon associated to the element.

Returns:
the icon associated to the element

getCategories

Category[] getCategories()
Returns the categories associated to the element.

Returns:
the categories associated to the element

addElementDescriptionChangeListener

void addElementDescriptionChangeListener(ElementDescriptionChangeListener listener)
Adds a element description change listener.

Parameters:
listener - - the listener
See Also:
ElementDescriptionChangeListener

removeElementDescriptionChangeListener

void removeElementDescriptionChangeListener(ElementDescriptionChangeListener listener)
Removes a element description change listener.

Parameters:
listener - - the listener
See Also:
ElementDescriptionChangeListener


To file bugs or suggest feature enhancements, visit the app.jbbres.com Bug Reporter website.

Additional documentation available online at http://app.jbbres.com/actions/developers.

Copyright � 2009-2011 app.jbbres.com. All Rights Reserved.