org.objectweb.fractal.explorer.menu
Class DefaultFractalMenuItem

java.lang.Object
  extended by org.objectweb.fractal.explorer.menu.DefaultFractalMenuItem
All Implemented Interfaces:
FractalMenuItem, org.objectweb.util.explorer.api.MenuItem

public abstract class DefaultFractalMenuItem
extends Object
implements org.objectweb.util.explorer.api.MenuItem, FractalMenuItem

Specialization of the menu item for entities having life cycle properties.

Version:
0.1
Author:
Jerome Moroy

Field Summary
 
Fields inherited from interface org.objectweb.util.explorer.api.MenuItem
DISABLED_STATUS, ENABLED_STATUS, NOT_VISIBLE_STATUS
 
Constructor Summary
DefaultFractalMenuItem()
           
 
Method Summary
 void actionPerformed(org.objectweb.util.explorer.api.MenuItemTreeView arg0)
          Call the appropriate actionPerformed depending on the status of the component (STARTED or STOPPED).
abstract  void actionStartedPerformed(org.objectweb.util.explorer.api.MenuItemTreeView arg0)
          Called when the Fractal component is started.
 void actionStoppedPerformed(org.objectweb.util.explorer.api.MenuItemTreeView arg0)
          Called when the Fractal component is stopped.
 int getStartedStatus(org.objectweb.util.explorer.api.TreeView arg0)
          Called when the Fractal component is started.
 int getStatus(org.objectweb.util.explorer.api.TreeView arg0)
          Compute if the component is started or not.
 int getStoppedStatus(org.objectweb.util.explorer.api.TreeView arg0)
          Called when the Fractal component is stopped.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultFractalMenuItem

public DefaultFractalMenuItem()
Method Detail

getStatus

public int getStatus(org.objectweb.util.explorer.api.TreeView arg0)
Compute if the component is started or not.

Specified by:
getStatus in interface org.objectweb.util.explorer.api.MenuItem

actionPerformed

public void actionPerformed(org.objectweb.util.explorer.api.MenuItemTreeView arg0)
                     throws Exception
Call the appropriate actionPerformed depending on the status of the component (STARTED or STOPPED).

Specified by:
actionPerformed in interface org.objectweb.util.explorer.api.MenuItem
Throws:
Exception

getStartedStatus

public int getStartedStatus(org.objectweb.util.explorer.api.TreeView arg0)
Description copied from interface: FractalMenuItem
Called when the Fractal component is started.

Specified by:
getStartedStatus in interface FractalMenuItem
Parameters:
arg0 - A view on the tree.
Returns:
The status of the menu item.

getStoppedStatus

public int getStoppedStatus(org.objectweb.util.explorer.api.TreeView arg0)
Description copied from interface: FractalMenuItem
Called when the Fractal component is stopped.

Specified by:
getStoppedStatus in interface FractalMenuItem
Parameters:
arg0 - A view on the tree.
Returns:
The status of the menu item.

actionStoppedPerformed

public void actionStoppedPerformed(org.objectweb.util.explorer.api.MenuItemTreeView arg0)
                            throws Exception
Description copied from interface: FractalMenuItem
Called when the Fractal component is stopped.

Specified by:
actionStoppedPerformed in interface FractalMenuItem
Parameters:
arg0 - The event.
Throws:
Exception

actionStartedPerformed

public abstract void actionStartedPerformed(org.objectweb.util.explorer.api.MenuItemTreeView arg0)
                                     throws Exception
Description copied from interface: FractalMenuItem
Called when the Fractal component is started.

Specified by:
actionStartedPerformed in interface FractalMenuItem
Parameters:
arg0 - The event.
Throws:
Exception