public function VocabularyRouteProvider::getRoutes in Drupal 8
Same name and namespace in other branches
- 9 core/modules/taxonomy/src/Entity/Routing/VocabularyRouteProvider.php \Drupal\taxonomy\Entity\Routing\VocabularyRouteProvider::getRoutes()
Provides routes for entities.
Parameters
\Drupal\Core\Entity\EntityTypeInterface $entity_type: The entity type
Return value
\Symfony\Component\Routing\RouteCollection|\Symfony\Component\Routing\Route[] Returns a route collection or an array of routes keyed by name, like route_callbacks inside 'routing.yml' files.
Overrides DefaultHtmlRouteProvider::getRoutes
File
- core/
modules/ taxonomy/ src/ Entity/ Routing/ VocabularyRouteProvider.php, line 14
Class
Namespace
Drupal\taxonomy\Entity\RoutingCode
public function getRoutes(EntityTypeInterface $entity_type) {
$collection = parent::getRoutes($entity_type);
if ($reset_page_route = $this
->getResetPageRoute($entity_type)) {
$collection
->add("entity.taxonomy_vocabulary.reset_form", $reset_page_route);
}
if ($overview_page_route = $this
->getOverviewPageRoute($entity_type)) {
$collection
->add("entity.taxonomy_vocabulary.overview_form", $overview_page_route);
}
return $collection;
}