function ActionExpression::prepareExecutionMetadataState
Overrides ExpressionInterface::prepareExecutionMetadataState
1 call to ActionExpression::prepareExecutionMetadataState()
- ActionExpression::checkIntegrity in src/
Plugin/ RulesExpression/ ActionExpression.php - Verifies that this expression is configured correctly.
File
-
src/
Plugin/ RulesExpression/ ActionExpression.php, line 173
Class
- ActionExpression
- Provides an executable action expression.
Namespace
Drupal\rules\Plugin\RulesExpressionCode
public function prepareExecutionMetadataState(ExecutionMetadataStateInterface $metadata_state, ExpressionInterface $until = NULL, $apply_assertions = TRUE) {
if ($until && $this->getUuid() === $until->getUuid()) {
return TRUE;
}
$action = $this->actionManager
->createInstance($this->configuration['action_id']);
// Make sure to refine context first, such that possibly refined definitions
// of provided context are respected.
$this->prepareContextWithMetadata($action, $metadata_state);
$this->addProvidedContextDefinitions($action, $metadata_state);
if ($apply_assertions) {
$this->assertMetadata($action, $metadata_state);
}
}