You are here

public function EntityRevisionConverter::__construct in Workbench Moderation 8

Same name and namespace in other branches
  1. 8.2 src/ParamConverter/EntityRevisionConverter.php \Drupal\workbench_moderation\ParamConverter\EntityRevisionConverter::__construct()

EntityRevisionConverter constructor.

Parameters

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity manager, needed by the parent class.

\Drupal\workbench_moderation\ModerationInformationInterface $moderation_info: The moderation info utility service.

\Drupal\Core\Entity\EntityRepositoryInterface $entity_repository: Entity repository.

Overrides EntityConverter::__construct

File

src/ParamConverter/EntityRevisionConverter.php, line 35

Class

EntityRevisionConverter
Defines a class for making sure the edit-route loads the current draft.

Namespace

Drupal\workbench_moderation\ParamConverter

Code

public function __construct(EntityTypeManagerInterface $entity_type_manager, ModerationInformationInterface $moderation_info, EntityRepositoryInterface $entity_repository) {
  parent::__construct($entity_type_manager, $entity_repository);
  $this->moderationInformation = $moderation_info;
}