function ContextProviderTrait::setProvidedValue

See also

\Drupal\rules\Context\ContextProviderInterface

9 calls to ContextProviderTrait::setProvidedValue()
DataCalculateValue::doExecute in src/Plugin/RulesAction/DataCalculateValue.php
Executes the action with the given context.
DataConvert::doExecute in src/Plugin/RulesAction/DataConvert.php
Executes the plugin.
EntityCreate::execute in src/Plugin/RulesAction/EntityCreate.php
Executes the plugin.
EntityFetchByField::doExecute in src/Plugin/RulesAction/EntityFetchByField.php
Executes the action with the given context.
EntityFetchById::doExecute in src/Plugin/RulesAction/EntityFetchById.php
Executes the action with the given context.

... See full list

File

src/Context/ContextProviderTrait.php, line 32

Class

ContextProviderTrait
A trait implementing the ContextProviderInterface.

Namespace

Drupal\rules\Context

Code

public function setProvidedValue($name, $value) {
    $context = $this->getProvidedContext($name);
    $new_context = Context::createFromContext($context, $value);
    $this->providedContext[$name] = $new_context;
    return $this;
}