Same name and namespace in other branches
  1. 2.x src/EntityClone/Content/ContentEntityCloneBase.php \Drupal\entity_clone\EntityClone\Content\ContentEntityCloneBase::__construct()

Constructs a new ContentEntityCloneBase.

Parameters

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity type manager.

string $entity_type_id: The entity type ID.

\Drupal\Component\Datetime\TimeInterface $time_service: A service for obtaining the system's time.

\Drupal\Core\Session\AccountProxyInterface $current_user: The current user.

File

src/EntityClone/Content/ContentEntityCloneBase.php, line 68

Class

ContentEntityCloneBase
Class Content Entity Clone Base.

Namespace

Drupal\entity_clone\EntityClone\Content

Code

public function __construct(EntityTypeManagerInterface $entity_type_manager, $entity_type_id, TimeInterface $time_service, AccountProxyInterface $current_user) {
    $this->entityTypeManager = $entity_type_manager;
    $this->entityTypeId = $entity_type_id;
    $this->timeService = $time_service;
    $this->currentUser = $current_user;
}