de.cau.cs.kieler.ksbase.core
Class KSBasEMenuContribution

java.lang.Object
  extended by de.cau.cs.kieler.ksbase.core.KSBasEMenuContribution
All Implemented Interfaces:
Serializable

public class KSBasEMenuContribution
extends Object
implements Serializable

A menu contribution, defined by an extension point. Contains a list of commands, sub menus and a data property.

See Also:
Serialized Form
Rating yellow
(2010-01-22) review by msp, skn

Constructor Summary
KSBasEMenuContribution(String dat)
          Creates a new menu contribution with the given data content (Id or locationURI).
 
Method Summary
 void addCommand(String transformationId)
          Adds a command to this contribution.
 void addSubMenu(KSBasEMenuContribution menu)
          Adds a sub menu to this contribution.
 LinkedList<String> getCommands()
          Returns the list of commands.
 String getData()
          Returns the string property.
 String getLabel()
          Returns the label.
 LinkedList<KSBasEMenuContribution> getMenus()
          Returns a list of all sub menus contained in this contribution.
 void setLabel(String value)
          Sets the label.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

KSBasEMenuContribution

public KSBasEMenuContribution(String dat)
Creates a new menu contribution with the given data content (Id or locationURI).

Parameters:
dat - The data property
Method Detail

addCommand

public final void addCommand(String transformationId)
Adds a command to this contribution.

Parameters:
transformationId - The id of the called transformation

addSubMenu

public final void addSubMenu(KSBasEMenuContribution menu)
Adds a sub menu to this contribution.

Parameters:
menu - the menu to add

getMenus

public final LinkedList<KSBasEMenuContribution> getMenus()
Returns a list of all sub menus contained in this contribution.

Returns:
A list of menu contributions

getCommands

public final LinkedList<String> getCommands()
Returns the list of commands.

Returns:
A list of commands

getData

public final String getData()
Returns the string property.

Returns:
The content of the data property

getLabel

public final String getLabel()
Returns the label.

Returns:
The label

setLabel

public final void setLabel(String value)
Sets the label.

Parameters:
value - the new label