RouteSubscriber::__construct

public RouteSubscriber::__construct(EntityManagerInterface $entity_manager, StateInterface $state)

Constructs a \Drupal\views\EventSubscriber\RouteSubscriber instance.

Parameters

\Drupal\Core\Entity\EntityManagerInterface $entity_manager: The entity manager.

\Drupal\Core\State\StateInterface $state: The state key value store.

File

core/modules/views/src/EventSubscriber/RouteSubscriber.php, line 62

Class

RouteSubscriber
Builds up the routes of all views.

Namespace

Drupal\views\EventSubscriber

Code

public function __construct(EntityManagerInterface $entity_manager, StateInterface $state) {
  $this->viewStorage = $entity_manager->getStorage('view');
  $this->state = $state;
}
doc_Drupal
2016-10-29 09:39:29
Comments
Leave a Comment

Please login to continue.