planetj.dataengine.action
Class ActionManager

java.lang.Object
  extended byplanetj.dataengine.action.ActionManager

public class ActionManager
extends java.lang.Object

The ActionManager manages what actions are registered.


Constructor Summary
protected ActionManager()
          ActionManager constructor.
 
Method Summary
 AbstractAction getAction(java.lang.String type, java.lang.String name)
          Gets the action for the given action type and name.
 ActionDescriptor getDefaultDescriptor(java.lang.String actionType, java.lang.String actionName)
          Gets the default registered descriptor for the given display type, action name, and action type.
 void registerAction(java.lang.String type, java.lang.String name, AbstractAction action)
          Puts the action for the given action type and name.
 void registerDefaultDescriptor(java.lang.String actionType, java.lang.String actionName, ActionDescriptor descriptor)
          Puts the action for the given action type and name.
static void setSingleton(ActionManager actionMgr)
          Allows a subclass of the ActionManager to be set as the singleton instance.
static ActionManager singleton()
          Gets the singleton instance of the ActionManager
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ActionManager

protected ActionManager()
ActionManager constructor.

Method Detail

getAction

public AbstractAction getAction(java.lang.String type,
                                java.lang.String name)
Gets the action for the given action type and name.

Returns:
action.

getDefaultDescriptor

public ActionDescriptor getDefaultDescriptor(java.lang.String actionType,
                                             java.lang.String actionName)
Gets the default registered descriptor for the given display type, action name, and action type.

Returns:
IRenderer.

registerAction

public void registerAction(java.lang.String type,
                           java.lang.String name,
                           AbstractAction action)
Puts the action for the given action type and name.

Returns:
action.

registerDefaultDescriptor

public void registerDefaultDescriptor(java.lang.String actionType,
                                      java.lang.String actionName,
                                      ActionDescriptor descriptor)
Puts the action for the given action type and name.

Returns:
action.

setSingleton

public static void setSingleton(ActionManager actionMgr)
Allows a subclass of the ActionManager to be set as the singleton instance. The singleton instance isn't synchronized, so this method must be invoked before the singleton is accessed.

Parameters:
actionMgr - new singleton instance

singleton

public static ActionManager singleton()
Gets the singleton instance of the ActionManager