function BreadcrumbBuilderInterface::applies

Same name in other branches
  1. 9 core/lib/Drupal/Core/Breadcrumb/BreadcrumbBuilderInterface.php \Drupal\Core\Breadcrumb\BreadcrumbBuilderInterface::applies()
  2. 8.9.x core/lib/Drupal/Core/Breadcrumb/BreadcrumbBuilderInterface.php \Drupal\Core\Breadcrumb\BreadcrumbBuilderInterface::applies()
  3. 10 core/lib/Drupal/Core/Breadcrumb/BreadcrumbBuilderInterface.php \Drupal\Core\Breadcrumb\BreadcrumbBuilderInterface::applies()

Whether this breadcrumb builder should be used to build the breadcrumb.

@todo Uncomment new method parameters before drupal:12.0.0, see https://www.drupal.org/project/drupal/issues/3459277.

Parameters

\Drupal\Core\Routing\RouteMatchInterface $route_match: The current route match. phpcs:disable Drupal.Commenting

\Drupal\Core\Cache\CacheableMetadata $cacheable_metadata: The cacheable metadata to add to if your check varies by or depends on something. Anything you specify here does not have to be repeated in the build() method as it will be merged in automatically. phpcs:enable

Return value

bool TRUE if this builder should be used or FALSE to let other builders decide.

8 methods override BreadcrumbBuilderInterface::applies()
BookBreadcrumbBuilder::applies in core/modules/book/src/BookBreadcrumbBuilder.php
Whether this breadcrumb builder should be used to build the breadcrumb.
BreadcrumbManager::applies in core/lib/Drupal/Core/Breadcrumb/BreadcrumbManager.php
Whether this breadcrumb builder should be used to build the breadcrumb.
CommentBreadcrumbBuilder::applies in core/modules/comment/src/CommentBreadcrumbBuilder.php
Whether this breadcrumb builder should be used to build the breadcrumb.
ForumListingBreadcrumbBuilder::applies in core/modules/forum/src/Breadcrumb/ForumListingBreadcrumbBuilder.php
Whether this breadcrumb builder should be used to build the breadcrumb.
ForumNodeBreadcrumbBuilder::applies in core/modules/forum/src/Breadcrumb/ForumNodeBreadcrumbBuilder.php
Whether this breadcrumb builder should be used to build the breadcrumb.

... See full list

File

core/lib/Drupal/Core/Breadcrumb/BreadcrumbBuilderInterface.php, line 31

Class

BreadcrumbBuilderInterface
Defines an interface for classes that build breadcrumbs.

Namespace

Drupal\Core\Breadcrumb

Code

public function applies(RouteMatchInterface $route_match);

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