Overview  Package   Class  Use  Tree  Deprecated  Index  Help 
PREV CLASS   NEXT CLASS FRAMES    NO FRAMES    All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD

org.alfresco.service.cmr.action
Interface ActionService

public interface ActionService
Action service interface
Author:
Roy Wetherall

Method Summary
createAction(String name)
          Create a new action
createAction(String name, Map<String,Serializable> params)
          Create a new action specifying the initial set of parameter values
createActionCondition(String name)
          Create an action condition
createActionCondition(String name, Map<String,Serializable> params)
          Create an action condition specifying the initial set of parameter values
createCompositeAction()
          Create a composite action
createCompositeActionCondition()
          Create a composite actionCondition
boolean
evaluateAction(Action action, NodeRef actionedUponNodeRef)
          Evaluted the conditions set on an action.
boolean
evaluateActionCondition(ActionCondition condition, NodeRef actionedUponNodeRef)
          Evaluate an action condition.
void
executeAction(Action action, NodeRef actionedUponNodeRef)
          The actions conditions are always checked.
void
executeAction(Action action, NodeRef actionedUponNodeRef, boolean checkConditions)
          The action is executed based on the asynchronous attribute of the action.
void
executeAction(Action action, NodeRef actionedUponNodeRef, boolean checkConditions, boolean executeAsynchronously)
          Executes the specified action upon the node reference provided.
getAction(NodeRef nodeRef, String actionId)
          Gets an action stored against a given node reference.
getActionConditionDefinition(String name)
          Get a named action condition definition
getActionConditionDefinitions()
          Get all the action condition definitions
getActionDefinition(String name)
          Get a named action definition
getActionDefinitions()
          Get all the action definitions
getActionDefinitions(NodeRef nodeRef)
          Get all the action definitions that are applicable for the given node, based on its type and aspects.
getActions(NodeRef nodeRef)
          Gets all the actions currently saved on the given node reference.
getParameterConstraint(String name)
          Get a named parameter constraint
getParameterConstraints()
          Get all the parameter constraints
void
removeAction(NodeRef nodeRef, Action action)
          Removes an action associated with a node reference.
void
removeAllActions(NodeRef nodeRef)
          Removes all actions associated with a node reference
void
saveAction(NodeRef nodeRef, Action action)
          Save an action against a node reference.
Method Detail
getActionDefinition
@Auditable(parameters="name")
ActionDefinition getActionDefinition(String name)
Get a named action definition
Parameters:
name - the name of the action definition
Returns:
the action definition

getActionDefinitions
@Auditable
List<ActionDefinitiongetActionDefinitions()
Get all the action definitions
Returns:
the list action definitions

getActionDefinitions
@Auditable(parameters="nodeRef")
List<ActionDefinitiongetActionDefinitions(NodeRef nodeRef)
Get all the action definitions that are applicable for the given node, based on its type and aspects.
Parameters:
nodeRef - the node reference
Returns:
a list of applicable action definitions

getActionConditionDefinition
@Auditable(parameters="name")
ActionConditionDefinition getActionConditionDefinition(String name)
Get a named action condition definition
Parameters:
name - the name of the action condition definition
Returns:
the action condition definition

getActionConditionDefinitions
@Auditable(parameters={})
List<ActionConditionDefinitiongetActionConditionDefinitions()
Get all the action condition definitions
Returns:
the list of action condition definitions

getParameterConstraint
@Auditable(parameters="name")
ParameterConstraint getParameterConstraint(String name)
Get a named parameter constraint
Parameters:
name - the name of the parameter constraint
Returns:
this parameter condition

getParameterConstraints
@Auditable(parameters={})
List<ParameterConstraintgetParameterConstraints()
Get all the parameter constraints
Returns:
the list of all parameter constraints

createAction
@Auditable(parameters="name")
Action createAction(String name)
Create a new action
Parameters:
name - the action definition name
Returns:
the action

createAction
@Auditable(parameters={
  "name",
  "params"
})
Action createAction(String name,
                    Map<String,Serializable> params)
Create a new action specifying the initial set of parameter values
Parameters:
name - the action definition name
params - the parameter values
Returns:
the action

createCompositeAction
@Auditable
CompositeAction createCompositeAction()
Create a composite action
Returns:
the composite action

createActionCondition
@Auditable(parameters="name")
ActionCondition createActionCondition(String name)
Create an action condition
Parameters:
name - the action condition definition name
Returns:
the action condition

createActionCondition
@Auditable(parameters={
  "name",
  "params"
})
ActionCondition createActionCondition(String name,
                                      Map<String,Serializable> params)
Create an action condition specifying the initial set of parameter values
Parameters:
name - the action condition definition name
params - the parameter values
Returns:
the action condition

createCompositeActionCondition
@Auditable
CompositeActionCondition createCompositeActionCondition()
Create a composite actionCondition
Returns:
the composite actionCondition

executeAction
@Auditable(parameters={
  "action",
  "actionedUponNodeRef"
})
void executeAction(Action action,
                   NodeRef actionedUponNodeRef)
The actions conditions are always checked.
Parameters:
action - the action
actionedUponNodeRef - the actioned upon node reference
See Also:
executeAction(Action, NodeRef, boolean)

executeAction
@Auditable(parameters={
  "action",
  "actionedUponNodeRef",
  "checkConditions"
})
void executeAction(Action action,
                   NodeRef actionedUponNodeRef,
                   boolean checkConditions)
The action is executed based on the asynchronous attribute of the action.
Parameters:
action - the action
actionedUponNodeRef - the actioned upon node reference
checkConditions - indicates whether the conditions should be checked
See Also:
executeAction(Action, NodeRef, boolean, boolean)

executeAction
@Auditable(parameters={
  "action",
  "actionedUponNodeRef",
  "checkConditions",
  "executeAsynchronously"
})
void executeAction(Action action,
                   NodeRef actionedUponNodeRef,
                   boolean checkConditions,
                   boolean executeAsynchronously)
Executes the specified action upon the node reference provided.

If specified that the conditions should be checked then any conditions set on the action are evaluated.

If the conditions fail then the action is not executed.

If an action has no conditions then the action will always be executed.

If the conditions are not checked then the action will always be executed.

Parameters:
action - the action
actionedUponNodeRef - the actioned upon node reference
checkConditions - indicates whether the conditions should be checked before executing the action
executeAsynchronously - indicates whether the action should be executed asychronously or not, this value overrides the value set on the action its self

evaluateAction
@Auditable(parameters={
  "action",
  "actionedUponNodeRef"
})
boolean evaluateAction(Action action,
                       NodeRef actionedUponNodeRef)
Evaluted the conditions set on an action.

Returns true if the action has no conditions.

If the action has more than one condition their results are combined using the 'AND' logical operator.

Parameters:
action - the action
actionedUponNodeRef - the actioned upon node reference
Returns:
true if the condition succeeds, false otherwise

evaluateActionCondition
@Auditable(parameters={
  "condition",
  "actionedUponNodeRef"
})
boolean evaluateActionCondition(ActionCondition condition,
                                NodeRef actionedUponNodeRef)
Evaluate an action condition.
Parameters:
condition - the action condition
actionedUponNodeRef - the actioned upon node reference
Returns:
true if the condition succeeds, false otherwise

saveAction
@Auditable(parameters={
  "nodeRef",
  "action"
})
void saveAction(NodeRef nodeRef,
                Action action)
Save an action against a node reference.

The node will be made configurable if it is not already.

If the action already exists then its details will be updated.

Parameters:
nodeRef - the node reference
action - the action

getActions
@Auditable(parameters="nodeRef")
List<ActiongetActions(NodeRef nodeRef)
Gets all the actions currently saved on the given node reference.
Parameters:
nodeRef - the node reference
Returns:
the list of actions

getAction
@Auditable(parameters={
  "nodeRef",
  "actionId"
})
Action getAction(NodeRef nodeRef,
                 String actionId)
Gets an action stored against a given node reference.

Returns null if the action can not be found.

Parameters:
nodeRef - the node reference
actionId - the action id
Returns:
the action

removeAction
@Auditable(parameters={
  "nodeRef",
  "action"
})
void removeAction(NodeRef nodeRef,
                  Action action)
Removes an action associated with a node reference.
Parameters:
nodeRef - the node reference
action - the action

removeAllActions
@Auditable(parameters="nodeRef")
void removeAllActions(NodeRef nodeRef)
Removes all actions associated with a node reference
Parameters:
nodeRef - the node reference

Overview  Package   Class  Use  Tree  Deprecated  Index  Help 
PREV CLASS   NEXT CLASS FRAMES    NO FRAMES    All Classes
SUMMARY: NESTED | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD

Copyright © 2005–2016 Alfresco Software. All rights reserved.

Java API documentation generated with DocFlex/Javadoc 1.6.1 using JavadocPro template set.