public function EntityInterface::createDuplicate

Creates a duplicate of the entity.

Return value

Drupal\Core\Entity\EntityInterface A clone of the current entity with all identifiers unset, so saving it inserts a new entity into the storage system.

2 methods override EntityInterface::createDuplicate()
Entity::createDuplicate in drupal/core/lib/Drupal/Core/Entity/Entity.php
Implements EntityInterface::createDuplicate().
ViewUI::createDuplicate in drupal/core/modules/views/views_ui/lib/Drupal/views_ui/ViewUI.php
Implements \Drupal\Core\Entity\EntityInterface::createDuplicate().

File

drupal/core/lib/Drupal/Core/Entity/EntityInterface.php, line 155
Definition of Drupal\Core\Entity\EntityInterface.

Class

EntityInterface
Defines a common interface for all entity objects.

Namespace

Drupal\Core\Entity

Code

public function createDuplicate();