function EntityCreate::__construct
Constructs an EntityCreate object.
Parameters
array $configuration: A configuration array containing information about the plugin instance.
string $plugin_id: The plugin ID for the plugin instance.
mixed $plugin_definition: The plugin implementation definition.
\Drupal\Core\Entity\EntityStorageInterface $storage: The entity storage service.
File
-
src/
Plugin/ RulesAction/ EntityCreate.php, line 55
Class
- EntityCreate
- Provides a generic 'Create a new entity' action.
Namespace
Drupal\rules\Plugin\RulesActionCode
public function __construct(array $configuration, $plugin_id, $plugin_definition, EntityStorageInterface $storage) {
parent::__construct($configuration, $plugin_id, $plugin_definition);
$this->storage = $storage;
$this->entityTypeId = $plugin_definition['entity_type_id'];
$this->bundleKey = $plugin_definition['bundle_key'];
}