Rational Developer for Power Systems Software
V7.6

com.ibm.etools.systems.application.visual.editor.commands
Class SetConnectionRoutingCommand

java.lang.Object
  extended by AbstractTransactionalCommand
      extended by com.ibm.etools.systems.application.visual.editor.commands.SetConnectionRoutingCommand

public class SetConnectionRoutingCommand
extends AbstractTransactionalCommand

Command that sets routing of connection editpart.


Field Summary
static String copyright
           
 
Constructor Summary
SetConnectionRoutingCommand(ConnectionEditPart connectionEditPart, Routing newRouting, TransactionalEditingDomain domain, String label, List affectedFiles)
           
 
Method Summary
 boolean canExecute()
           
 boolean canUndo()
           
protected  CommandResult doExecuteWithResult(IProgressMonitor monitor, IAdaptable info)
           
 Routing getNewRouting()
          Get old ruter
 Routing getOldRouting()
          Get old ruter
 void redo()
          Re-executes the Command.
 void undo()
          Undoes the changes performed during execute().
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

copyright

public static final String copyright
See Also:
Constant Field Values
Constructor Detail

SetConnectionRoutingCommand

public SetConnectionRoutingCommand(ConnectionEditPart connectionEditPart,
                                   Routing newRouting,
                                   TransactionalEditingDomain domain,
                                   String label,
                                   List affectedFiles)
Parameters:
label -
Method Detail

getOldRouting

public Routing getOldRouting()
Get old ruter


getNewRouting

public Routing getNewRouting()
Get old ruter


canExecute

public boolean canExecute()
Returns:
true if the command can be executed

canUndo

public boolean canUndo()
Returns:
true if the command can be undone. This method should only be called after execute() or redo() has been called.

undo

public void undo()
Undoes the changes performed during execute(). This method should only be called after execute has been called, and only when canUndo() returns true.

See Also:
canUndo()

redo

public void redo()
Re-executes the Command. This method should only be called after undo() has been called.


doExecuteWithResult

protected CommandResult doExecuteWithResult(IProgressMonitor monitor,
                                            IAdaptable info)
                                     throws ExecutionException
Throws:
ExecutionException

Rational Developer for Power Systems Software
V7.6

Copyright © 2011 IBM Corp. All Rights Reserved.

Note: This documentation is for part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.