function RulesComponent::create

Constructs the object.

Parameters

\Drupal\rules\Engine\ExpressionInterface $expression: The expression of the component.

Return value

static

6 calls to RulesComponent::create()
CoreIntegrationTest::testGlobalContext in tests/src/Kernel/CoreIntegrationTest.php
Tests using global context.
EventComponentResolver::getMultiple in src/ComponentResolver/EventComponentResolver.php
Gets multiple components.
ReactionRuleConfig::getComponent in src/Entity/ReactionRuleConfig.php
Gets the Rules component that is invoked when the events are dispatched. The returned component has the definitions of the available event context set.
RulesComponent::createFromConfiguration in src/Engine/RulesComponent.php
Creates a component based on the given configuration array.
RulesComponentTest::testGetState in tests/src/Unit/Integration/Engine/RulesComponentTest.php
@covers ::getState

... See full list

File

src/Engine/RulesComponent.php, line 54

Class

RulesComponent
Handles executable Rules components.

Namespace

Drupal\rules\Engine

Code

public static function create(ExpressionInterface $expression) {
    return new static($expression);
}