Automattic\WooCommerce\Admin\RemoteInboxNotifications

PassRuleProcessor{}WC 1.0

Rule processor that passes.

Хуков нет.

Использование

$PassRuleProcessor = new PassRuleProcessor();
// use class methods

Методы

  1. public process( $rule, $stored_state )
  2. public validate( $rule )

Код PassRuleProcessor{} WC 7.1.0

class PassRuleProcessor implements RuleProcessorInterface {
	/**
	 * Passes the rule.
	 *
	 * @param object $rule         The specific rule being processed by this rule processor.
	 * @param object $stored_state Stored state.
	 *
	 * @return bool Always true.
	 */
	public function process( $rule, $stored_state ) {
		return true;
	}

	/**
	 * Validates the rule.
	 *
	 * @param object $rule The rule to validate.
	 *
	 * @return bool Pass/fail.
	 */
	public function validate( $rule ) {
		return true;
	}
}