You are here

public function ViewModeConverter::__construct in Hierarchical Term Formatter 8

Constructs a ViewModeConverter object.

Parameters

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_manager: The entity manager service.

File

tests/modules/hierarchical_term_formatter_test/src/ParamConverter/ViewModeConverter.php, line 27

Class

ViewModeConverter
Converts route parameter into loaded view mode.

Namespace

Drupal\hierarchical_term_formatter_test\ParamConverter

Code

public function __construct(EntityTypeManagerInterface $entity_manager) {
  $this->storage = $entity_manager
    ->getStorage('entity_view_mode');
}