de.cau.cs.kieler.ksbase.ui.utils
Class TransformationUtils

java.lang.Object
  extended by de.cau.cs.kieler.ksbase.ui.utils.TransformationUtils
All Implemented Interfaces:
ITransformationEventListener

public class TransformationUtils
extends Object
implements ITransformationEventListener

Utilities that may be called from Xtend.

Rating proposed yellow
(2010-03-22)

Constructor Summary
TransformationUtils()
           
 
Method Summary
 String getFileNameOfActiveEditor()
          Get the file name of the currently active editor.
static EObject getPostTransformationSelection()
          Get the object that is selected after the execution of the transformation.
static void setPostTransformationSelection(Object e)
          Sets the object that should be selected after the transformation has been executed.
 void transformationAboutToExecute(Object[] args)
          Pre-transformation code, empty right now.
 void transformationExecuted(Object[] args)
          Sets the diagram editor selection to the selection object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TransformationUtils

public TransformationUtils()
Method Detail

setPostTransformationSelection

public static void setPostTransformationSelection(Object e)
Sets the object that should be selected after the transformation has been executed.

Parameters:
e - The object to select

getPostTransformationSelection

public static EObject getPostTransformationSelection()
Get the object that is selected after the execution of the transformation.

Returns:
the selected EObject

transformationAboutToExecute

public void transformationAboutToExecute(Object[] args)
Pre-transformation code, empty right now.

Specified by:
transformationAboutToExecute in interface ITransformationEventListener
Parameters:
args - Empty arguments.

transformationExecuted

public void transformationExecuted(Object[] args)
Sets the diagram editor selection to the selection object.

Specified by:
transformationExecuted in interface ITransformationEventListener
Parameters:
args - The transformation arguments, see TransformationUIManager

getFileNameOfActiveEditor

public String getFileNameOfActiveEditor()
Get the file name of the currently active editor.

Returns:
the file name.