interface CacheableRouteProviderInterface

Same name in other branches
  1. 9 core/lib/Drupal/Core/Routing/CacheableRouteProviderInterface.php \Drupal\Core\Routing\CacheableRouteProviderInterface
  2. 8.9.x core/lib/Drupal/Core/Routing/CacheableRouteProviderInterface.php \Drupal\Core\Routing\CacheableRouteProviderInterface
  3. 11.x core/lib/Drupal/Core/Routing/CacheableRouteProviderInterface.php \Drupal\Core\Routing\CacheableRouteProviderInterface

Extends the router provider interface to provide caching support.

Hierarchy

Expanded class hierarchy of CacheableRouteProviderInterface

All classes that implement CacheableRouteProviderInterface

2 files declare their use of CacheableRouteProviderInterface
WorkspaceRequestSubscriber.php in core/modules/workspaces/src/EventSubscriber/WorkspaceRequestSubscriber.php
WorkspaceRequestSubscriberTest.php in core/modules/workspaces/tests/src/Unit/WorkspaceRequestSubscriberTest.php

File

core/lib/Drupal/Core/Routing/CacheableRouteProviderInterface.php, line 8

Namespace

Drupal\Core\Routing
View source
interface CacheableRouteProviderInterface extends RouteProviderInterface {
    
    /**
     * Adds a cache key part to be used in the cache ID of the route collection.
     *
     * @param string $cache_key_provider
     *   The provider of the cache key part.
     * @param string $cache_key_part
     *   A string to be used as a cache key part.
     */
    public function addExtraCacheKeyPart($cache_key_provider, $cache_key_part);

}

Members

Title Sort descending Modifiers Object type Summary Overrides
CacheableRouteProviderInterface::addExtraCacheKeyPart public function Adds a cache key part to be used in the cache ID of the route collection. 1

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