You are here

public function EntityCloneEvent::__construct in Entity Clone 8

Constructs an EntityCloneEvent object.

Parameters

\Drupal\Core\Entity\EntityInterface $entity: The original entity that was cloned.

\Drupal\Core\Entity\EntityInterface $cloned_entity: The clone of the original entity.

array $properties: The entity's properties.

File

src/Event/EntityCloneEvent.php, line 44

Class

EntityCloneEvent
Represents entity selection as event.

Namespace

Drupal\entity_clone\Event

Code

public function __construct(EntityInterface $entity, EntityInterface $cloned_entity, array $properties = []) {
  $this->entity = $entity;
  $this->clonedEntity = $cloned_entity;
  $this->properties = $properties;
}