org.weda.action.impl
Class ActionRegistryImpl

java.lang.Object
  extended by org.weda.action.impl.ActionRegistryImpl
All Implemented Interfaces:
ActionRegistry

public class ActionRegistryImpl
extends java.lang.Object
implements ActionRegistry

Цель: сервис, предоставляющий доступ к действиям

Author:
tim

Constructor Summary
ActionRegistryImpl()
           
 
Method Summary
 void addActionListener(ActionListener listener)
          Метод добавляет слушателя выполнения действий к реестру.
protected  void cacheExecutedActionInfo(ExecutedActionInfoImpl actionInfo)
           
 java.util.List<ActionListener> collectListenersForAction(ActionExecutionContext eContext)
           
protected  Action createAction(java.lang.Class actionClass)
           
 ExecutedActionInfo executeAction(ActionExecutionContext context)
          Метод выполняет действие.
protected  void extractActionParameters(ActionDescriptor actionDescriptor)
           
 java.util.List<ActionState> getActionsStates(ActionContainer targetObject, java.lang.Class targetClass)
          Метод возвращает список состояний действий досупных для указанного целевого объекта.
protected  org.weda.action.impl.ActionRegistryImpl.ActionStackEntity getActionStackEntity()
           
 ExecutedActionInfo getLastExecutedActionInfo()
          Метод возвращает информацию о последнем выполненном действии.
 java.lang.String getMessageCategory()
           
 boolean hasRegisteredActions(java.lang.Class targetClass, ActionContainer targetObject)
          Метод вернет TRUE если в реестре есть действия зарегистрированные для целевого класса.
 void init()
           
protected  ExecutedActionInfoImpl proccedLinkedActions(ActionExecutionContext ctx, ExecutedActionInfoImpl actionInfo)
           
 boolean removeActionListener(ActionListener listener)
          Метод удаляет слушателя выполнения действий из реестра.
 void setActionDescriptors(java.util.List<ActionDescriptor> actionDescriptors)
           
 void setActionListenersConfig(java.util.List<ActionListener> actionListenersConfig)
           
 void setCacheManager(CacheManager cacheManager)
           
 void setMessageCategory(java.lang.String messageCategory)
           
 void setMessages(MessagesRegistry messages)
           
 void setObjectDescriptorRegistry(ObjectDescriptorRegistry objectDescriptorRegistry)
           
 void setObjectEnhancer(ObjectEnhancer objectEnhancer)
           
 void setPropertyValue(PropertyValue propertyValue)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ActionRegistryImpl

public ActionRegistryImpl()
Method Detail

init

public void init()
          throws ActionRegistryException
Throws:
ActionRegistryException

removeActionListener

public boolean removeActionListener(ActionListener listener)
Description copied from interface: ActionRegistry
Метод удаляет слушателя выполнения действий из реестра.

Specified by:
removeActionListener in interface ActionRegistry

addActionListener

public void addActionListener(ActionListener listener)
Description copied from interface: ActionRegistry
Метод добавляет слушателя выполнения действий к реестру.

Specified by:
addActionListener in interface ActionRegistry

collectListenersForAction

public java.util.List<ActionListener> collectListenersForAction(ActionExecutionContext eContext)

setActionDescriptors

public void setActionDescriptors(java.util.List<ActionDescriptor> actionDescriptors)

hasRegisteredActions

public boolean hasRegisteredActions(java.lang.Class targetClass,
                                    ActionContainer targetObject)
Description copied from interface: ActionRegistry
Метод вернет TRUE если в реестре есть действия зарегистрированные для целевого класса. Если целевой класс реализует интерфейс GlobalActionsProvider тогда метод вернет TRUE если в реестре есть хотя бы одно глобальное действие.

Specified by:
hasRegisteredActions in interface ActionRegistry
Parameters:
targetClass - целевой класс.

getActionsStates

public java.util.List<ActionState> getActionsStates(ActionContainer targetObject,
                                                    java.lang.Class targetClass)
                                             throws ActionRegistryException
Description copied from interface: ActionRegistry
Метод возвращает список состояний действий досупных для указанного целевого объекта. Состояния глобальных действий будут присутствовать в списке в том и только том случае если целевой объект реализует интерфейс GlobalActionsProvider.

Specified by:
getActionsStates in interface ActionRegistry
Parameters:
targetObject - целевой объект
Throws:
ActionRegistryException

executeAction

public ExecutedActionInfo executeAction(ActionExecutionContext context)
                                 throws ActionRegistryException
Description copied from interface: ActionRegistry
Метод выполняет действие.

Specified by:
executeAction in interface ActionRegistry
Throws:
ActionRegistryException

proccedLinkedActions

protected ExecutedActionInfoImpl proccedLinkedActions(ActionExecutionContext ctx,
                                                      ExecutedActionInfoImpl actionInfo)
                                               throws java.lang.Exception
Throws:
java.lang.Exception

extractActionParameters

protected void extractActionParameters(ActionDescriptor actionDescriptor)
                                throws ActionRegistryException
Throws:
ActionRegistryException

createAction

protected Action createAction(java.lang.Class actionClass)
                       throws ObjectEnhancerException
Throws:
ObjectEnhancerException

setObjectDescriptorRegistry

public void setObjectDescriptorRegistry(ObjectDescriptorRegistry objectDescriptorRegistry)

setPropertyValue

public void setPropertyValue(PropertyValue propertyValue)

setCacheManager

public void setCacheManager(CacheManager cacheManager)

cacheExecutedActionInfo

protected void cacheExecutedActionInfo(ExecutedActionInfoImpl actionInfo)

getLastExecutedActionInfo

public ExecutedActionInfo getLastExecutedActionInfo()
Description copied from interface: ActionRegistry
Метод возвращает информацию о последнем выполненном действии.

Specified by:
getLastExecutedActionInfo in interface ActionRegistry

getActionStackEntity

protected org.weda.action.impl.ActionRegistryImpl.ActionStackEntity getActionStackEntity()

getMessageCategory

public java.lang.String getMessageCategory()

setMessageCategory

public void setMessageCategory(java.lang.String messageCategory)

setObjectEnhancer

public void setObjectEnhancer(ObjectEnhancer objectEnhancer)

setMessages

public void setMessages(MessagesRegistry messages)

setActionListenersConfig

public void setActionListenersConfig(java.util.List<ActionListener> actionListenersConfig)


Copyright © 2005-2006 . All Rights Reserved.