Support for linking and unlinking rules.

- Link and unlink actions avaible to allow one rule node to reuse the rule set from another rule set.
- Methods added to rule service API to get information about linked to and linked from rule nodes.

Note: 
- The action execution queue REST API can be used to call the link and unlink actions.
- The rule set REST API needs to be extended to provid information about what links to and from a rule node.



git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@18670 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Roy Wetherall
2010-02-17 04:25:17 +00:00
parent e174e39005
commit 8a0dc74bca
7 changed files with 577 additions and 3 deletions

View File

@@ -237,4 +237,34 @@ public interface RuleService
*/
@Auditable(key = Auditable.Key.RETURN, parameters = {"action"})
public NodeRef getOwningNodeRef(Action action);
/**
* Indicates whether the passed rule node reference is linked to another
* rule node.
*
* @param nodeRef rule node reference
* @return boolean true if linked, false otherwise
*/
@Auditable(key = Auditable.Key.RETURN, parameters = {"nodeRef"})
public boolean isLinkedToRuleNode(NodeRef nodeRef);
/**
* Get the node reference to the rule node which the rule node links to. Returns null
* if rules are not linked.
*
* @param nodeRef node reference of a rule node
* @return NodeRef reference to the
*/
@Auditable(key = Auditable.Key.RETURN, parameters = {"nodeRef"})
public NodeRef getLinkedToRuleNode(NodeRef nodeRef);
/**
* Get a list of the all the rule nodes that link to the passed rule node.
* Returns an empty list if none link.
*
* @param nodeRef node reference of a rule node
* @return List<NodeRef> list of rule nodes that link to this passed rule node, empty if none
*/
@Auditable(key = Auditable.Key.RETURN, parameters = {"nodeRef"})
public List<NodeRef> getLinkedFromRuleNodes(NodeRef nodeRef);
}