UML

org.topcased.modeler.uml.sequencediagram.commands.update
Class MessageUpdateCommand

java.lang.Object
  extended by org.eclipse.gef.commands.Command
      extended by org.topcased.modeler.uml.sequencediagram.commands.update.MessageUpdateCommand

public class MessageUpdateCommand
extends org.eclipse.gef.commands.Command

Command to update the message parameters


Constructor Summary
MessageUpdateCommand(org.eclipse.uml2.uml.Message msg, org.eclipse.uml2.uml.NamedElement sig, java.util.Collection values)
          Constructor
 
Method Summary
 void execute()
          Get the old values and set the new ones
protected  void getOldValues()
          Get the old values
 void redo()
          Update the message parameters
protected  void setValues()
          Set the values on the message
protected  void switchValues()
          Switch the old and new values
 void undo()
          Undo the update
 
Methods inherited from class org.eclipse.gef.commands.Command
canExecute, canUndo, chain, dispose, getDebugLabel, getLabel, setDebugLabel, setLabel
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MessageUpdateCommand

public MessageUpdateCommand(org.eclipse.uml2.uml.Message msg,
                            org.eclipse.uml2.uml.NamedElement sig,
                            java.util.Collection values)
Constructor

Parameters:
msg - the message to update
sig - the signature
values - the list of ValueSpecification
Method Detail

execute

public void execute()
Get the old values and set the new ones

Overrides:
execute in class org.eclipse.gef.commands.Command
See Also:
Command.execute()

getOldValues

protected void getOldValues()
Get the old values


switchValues

protected void switchValues()
Switch the old and new values


setValues

protected void setValues()
Set the values on the message


redo

public void redo()
Update the message parameters

Overrides:
redo in class org.eclipse.gef.commands.Command
See Also:
Command.redo()

undo

public void undo()
Undo the update

Overrides:
undo in class org.eclipse.gef.commands.Command
See Also:
Command.undo()

UML

Copyright (c) 2005 TOPCASED Contributors 2005 - 2007. All rights reserved.