|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.gef.commands.Command
vocleditor.commands.CreateAssociationRoleCommand
public class CreateAssociationRoleCommand
Connects two ClassifierRoles via an AssociationRole.
Constructor Summary | |
---|---|
CreateAssociationRoleCommand()
Constructor for the command class. |
Method Summary | |
---|---|
boolean |
canExecute()
True if the command could be executed, false otherwise. |
void |
execute()
Entry point for command execution. |
VOCLModel.AssociationRole |
getAssociationRole()
Returns the association role. |
VOCLModel.ClassifierRole |
getSource()
Returns the source classifier role. |
VOCLModel.ClassifierRole |
getTarget()
Returns the target classifier role. |
void |
redo()
Redo command execution. |
void |
setAssociationRole(VOCLModel.AssociationRole associationRole)
Sest the association role. |
void |
setCommandAttributes(VOCLModel.ClassifierRole source,
VOCLModel.ClassifierRole target,
java.lang.String name)
Sets the command attributes. |
void |
setName(java.lang.String name)
Sets the name of the association role. |
void |
setSource(VOCLModel.ClassifierRole newSource)
Sets the source classifier role. |
void |
setTarget(VOCLModel.ClassifierRole newTarget)
Sets the target classifier role. |
void |
undo()
Undo command execution. |
Methods inherited from class org.eclipse.gef.commands.Command |
---|
canUndo, chain, dispose, getDebugLabel, getLabel, setDebugLabel, setLabel |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CreateAssociationRoleCommand()
Method Detail |
---|
public boolean canExecute()
canExecute
in class org.eclipse.gef.commands.Command
public void execute()
Label
and set it.
execute
in class org.eclipse.gef.commands.Command
public void redo()
redo
in class org.eclipse.gef.commands.Command
public void undo()
undo
in class org.eclipse.gef.commands.Command
public VOCLModel.ClassifierRole getSource()
public VOCLModel.AssociationRole getAssociationRole()
public VOCLModel.ClassifierRole getTarget()
public void setSource(VOCLModel.ClassifierRole newSource)
newSource
- the source classifier role to setpublic void setTarget(VOCLModel.ClassifierRole newTarget)
newTarget
- the target classifier role to setpublic void setAssociationRole(VOCLModel.AssociationRole associationRole)
associationRole
- the association role to setpublic void setName(java.lang.String name)
name
- the name of the association rolepublic void setCommandAttributes(VOCLModel.ClassifierRole source, VOCLModel.ClassifierRole target, java.lang.String name)
source
- the source classifier roletarget
- the target classifier rolename
- the name of the association role
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |