Class OnPropertyUpdateRuleTrigger

java.lang.Object
org.alfresco.repo.rule.ruletrigger.RuleTriggerAbstractBase
org.alfresco.repo.rule.ruletrigger.OnPropertyUpdateRuleTrigger
All Implemented Interfaces:
NodeServicePolicies.OnUpdatePropertiesPolicy, ClassPolicy, Policy, RuleTrigger

public class OnPropertyUpdateRuleTrigger extends RuleTriggerAbstractBase implements NodeServicePolicies.OnUpdatePropertiesPolicy
On propety update trigger
Author:
Roy Wetherall
  • Constructor Details

    • OnPropertyUpdateRuleTrigger

      public OnPropertyUpdateRuleTrigger()
  • Method Details

    • setOnNewContent

      public void setOnNewContent(boolean onNewContent)
      If set to true the trigger will fire on new content, otherwise it will fire on content update
      Parameters:
      onNewContent - indicates whether to fire on content create or update
    • setIgnoreEmptyContent

      public void setIgnoreEmptyContent(boolean ignoreEmptyContent)
      If set to true, then we consider zero byte content to be equivalent to no content.
      Parameters:
      ignoreEmptyContent - boolean
    • setTriggerParentRules

      public void setTriggerParentRules(boolean triggerParentRules)
      Indicates whether the parent rules should be triggered or the rules on the node itself
      Parameters:
      triggerParentRules - true trigger parent rules, false otherwise
    • setRuntimeRuleService

      public void setRuntimeRuleService(RuntimeRuleService runtimeRuleService)
      Set the rule service
    • registerRuleTrigger

      public void registerRuleTrigger()
      Description copied from interface: RuleTrigger
      Register the rule trigger
      Specified by:
      registerRuleTrigger in interface RuleTrigger
    • onUpdateProperties

      public void onUpdateProperties(NodeRef nodeRef, Map<QName,Serializable> before, Map<QName,Serializable> after)
      Triggers rules if properties have been updated
      Specified by:
      onUpdateProperties in interface NodeServicePolicies.OnUpdatePropertiesPolicy
      Parameters:
      nodeRef - reference to the updated node
      before - the node's properties before the change
      after - the node's properties after the change