05 June 05
ConditionTestedEvent, continued (tag 'memelet-aspectj-day5')
Ok, back to condition-testing events. We need a pointcut that will match the call to Condition.isAllowed from the ConditionNode.assertTuple. This joinpoint will match the call, and also provide is the ConditionNode instance:
But in order to send the ConditionTestedEvent we also need the arguments of the ConditionNode.assertTuple call:
ActivationCreate/CancelledEvent
Now we get to hard stuff. Its hard only because of the implementation of WorkingMemory.modifyObject, which does a retract followed by an assert. This could cause lots of activation cancels, immediatly followed by activation creates for the same rule. In this case, we don't want to send any events because the activation changes were only an internal implemenation detail.
