de.cau.cs.kieler.viewmanagement.effects
Class CompartmentCollapseExpandEffect

java.lang.Object
  extended by de.cau.cs.kieler.viewmanagement.AEffect
      extended by de.cau.cs.kieler.viewmanagement.effects.CompartmentCollapseExpandEffect

public class CompartmentCollapseExpandEffect
extends AEffect

This Effect collapses or expands compartments. The execute() method expands while the undo method collapses.

Rating red

Constructor Summary
CompartmentCollapseExpandEffect(int theCompartmentLevel)
          The compartment level gives the hierarchy to which to search for compartments to collapse.
 
Method Summary
 void execute()
          Abstract method to execute a specific effect.
 void setTarget(EditPart target)
          Method to set the target of the effect.
 void undo()
          Undo the effect, i.e.
 
Methods inherited from class de.cau.cs.kieler.viewmanagement.AEffect
getAffectedObject, setParameters
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CompartmentCollapseExpandEffect

public CompartmentCollapseExpandEffect(int theCompartmentLevel)
The compartment level gives the hierarchy to which to search for compartments to collapse.

Parameters:
theCompartmentLevel - hierarchy level. 0 means only exactly the given EditPart.
Method Detail

execute

public void execute()
Description copied from class: AEffect
Abstract method to execute a specific effect. Must be implemented by the developer of the effect. Here, you will have to implement the exact behaviour of the effect.

Specified by:
execute in class AEffect

undo

public void undo()
Undo the effect, i.e. expand a collapsed compartment.


setTarget

public void setTarget(EditPart target)
Description copied from class: AEffect
Method to set the target of the effect. This is the EditPart that will be modified or otherwise worked with by the effect.

Overrides:
setTarget in class AEffect
Parameters:
target - the target of the effect