Automattic\WooCommerce\Admin\RemoteSpecs\RuleProcessors
NotRuleProcessor::process
Evaluates the rules in the operand and negates the result.
Method of the class: NotRuleProcessor{}
No Hooks.
Returns
true|false. The result of the operation.
Usage
$NotRuleProcessor = new NotRuleProcessor(); $NotRuleProcessor->process( $rule, $stored_state );
- $rule(object) (required)
- The specific rule being processed by this rule processor.
- $stored_state(object) (required)
- Stored state.
NotRuleProcessor::process() NotRuleProcessor::process code WC 10.6.2
public function process( $rule, $stored_state ) {
$evaluated_operand = $this->rule_evaluator->evaluate(
$rule->operand,
$stored_state
);
return ! $evaluated_operand;
}