function ExecutionState::setVariable

Overrides ExecutionStateInterface::setVariable

File

src/Context/ExecutionState.php, line 80

Class

ExecutionState
The rules execution state.

Namespace

Drupal\rules\Context

Code

public function setVariable($name, ContextDefinitionInterface $definition, $value) {
    $data = $this->getTypedDataManager()
        ->create($definition->getDataDefinition(), $value);
    $this->setVariableData($name, $data);
    return $this;
}