function RouteSubscriberBase::buildRoutes

Provides new routes during the RoutingEvents::STATIC phase.

This is the object-oriented equivalent of a 'route_callbacks' entry in a *.routing.yml file.

Return value

\Symfony\Component\Routing\RouteCollection A collection of new routes to add.

1 call to RouteSubscriberBase::buildRoutes()
RouteSubscriberBase::onBuildRoutes in core/lib/Drupal/Core/Routing/RouteSubscriberBase.php
Delegates the route building to self::buildRoutes().
1 method overrides RouteSubscriberBase::buildRoutes()
RouteSubscriber::buildRoutes in core/modules/views/src/EventSubscriber/RouteSubscriber.php
Provides new routes during the RoutingEvents::STATIC phase.

File

core/lib/Drupal/Core/Routing/RouteSubscriberBase.php, line 22

Class

RouteSubscriberBase
Provides a base implementation for routing event subscribers.

Namespace

Drupal\Core\Routing

Code

protected function buildRoutes() : RouteCollection {
  return new RouteCollection();
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.