act_threshold variable

The act_threshold variable is the value of the threshold attribute, which is the defined threshold value, on the <computedThreshold> or <eventCountThreshold> element of a threshold rule.

Details

The act_threshold variable is valid only within a threshold rule.

If a rule is defined with a grouping key, the act_eventCount, act_eventList, and act_threshold variables are not valid within the following expression contexts:
  • Life cycle actions
  • <filteringPredicate> within <activateOnEvent> or <deactivateOnEvent> within <activationInterval>
  • <computedValue>
This is because in this case, the rule variables apply only to a rule instance, and rule instances do not exist at the time that these expressions are run.

Coding example

The following code accesses the act_lib variable to obtain a defined threshold value:
int threshold = act_lib.getIntVariable(IACTLibrary.THRESHOLD);