BreadcrumbManager::__construct

public BreadcrumbManager::__construct(ModuleHandlerInterface $module_handler) Constructs a \Drupal\Core\Breadcrumb\BreadcrumbManager object. Parameters \Drupal\Core\Extension\ModuleHandlerInterface $module_handler: The module handler. File core/lib/Drupal/Core/Breadcrumb/BreadcrumbManager.php, line 49 Class BreadcrumbManager Provides a breadcrumb manager. Namespace Drupal\Core\Breadcrumb Code public function __construct(ModuleHandlerInterface $module_handler) { $this->moduleHandl

BreadcrumbManager

Provides a breadcrumb manager. Can be assigned any number of BreadcrumbBuilderInterface objects by calling the addBuilder() method. When build() is called it iterates over the objects in priority order and uses the first one that returns TRUE from BreadcrumbBuilderInterface::applies() to build the breadcrumbs. Hierarchy class \Drupal\Core\Breadcrumb\BreadcrumbManager implements ChainBreadcrumbBuilderInterface See also \Drupal\Core\DependencyInjection\Compiler\RegisterBreadcrumbBuilderPass F

BreadcrumbBuilderInterface::build

public BreadcrumbBuilderInterface::build(RouteMatchInterface $route_match) Builds the breadcrumb. Parameters \Drupal\Core\Routing\RouteMatchInterface $route_match: The current route match. Return value \Drupal\Core\Breadcrumb\Breadcrumb A breadcrumb. File core/lib/Drupal/Core/Breadcrumb/BreadcrumbBuilderInterface.php, line 33 Class BreadcrumbBuilderInterface Defines an interface for classes that build breadcrumbs. Namespace Drupal\Core\Breadcrumb Code public function build(RouteMatch

BreadcrumbManager::$sortedBuilders

Holds the array of breadcrumb builders sorted by priority. Set to NULL if the array needs to be re-calculated. Type: \Drupal\Core\Breadcrumb\BreadcrumbBuilderInterface[]|null File core/lib/Drupal/Core/Breadcrumb/BreadcrumbManager.php, line 41 Class BreadcrumbManager Provides a breadcrumb manager. Namespace Drupal\Core\Breadcrumb Code protected $sortedBuilders;

BreadcrumbManager::$moduleHandler

The module handler to invoke the alter hook. Type: \Drupal\Core\Extension\ModuleHandlerInterface File core/lib/Drupal/Core/Breadcrumb/BreadcrumbManager.php, line 25 Class BreadcrumbManager Provides a breadcrumb manager. Namespace Drupal\Core\Breadcrumb Code protected $moduleHandler;

BreadcrumbManager::$builders

Holds arrays of breadcrumb builders, keyed by priority. Type: array File core/lib/Drupal/Core/Breadcrumb/BreadcrumbManager.php, line 32 Class BreadcrumbManager Provides a breadcrumb manager. Namespace Drupal\Core\Breadcrumb Code protected $builders = array();

BreadcrumbBuilderInterface::applies

public BreadcrumbBuilderInterface::applies(RouteMatchInterface $route_match) Whether this breadcrumb builder should be used to build the breadcrumb. Parameters \Drupal\Core\Routing\RouteMatchInterface $route_match: The current route match. Return value bool TRUE if this builder should be used or FALSE to let other builders decide. File core/lib/Drupal/Core/Breadcrumb/BreadcrumbBuilderInterface.php, line 22 Class BreadcrumbBuilderInterface Defines an interface for classes that build bread

Breadcrumb::getLinks

public Breadcrumb::getLinks() Gets the breadcrumb links. Return value \Drupal\Core\Link[] File core/lib/Drupal/Core/Breadcrumb/Breadcrumb.php, line 29 Class Breadcrumb Used to return generated breadcrumbs with associated cacheability metadata. Namespace Drupal\Core\Breadcrumb Code public function getLinks() { return $this->links; }

Breadcrumb::setLinks

public Breadcrumb::setLinks(array $links) Sets the breadcrumb links. Parameters \Drupal\Core\Link[] $links: The breadcrumb links. Return value $this Throws \LogicException Thrown when setting breadcrumb links after they've already been set. File core/lib/Drupal/Core/Breadcrumb/Breadcrumb.php, line 44 Class Breadcrumb Used to return generated breadcrumbs with associated cacheability metadata. Namespace Drupal\Core\Breadcrumb Code public function setLinks(array $links) { if (!empty(

Breadcrumb::toRenderable

public Breadcrumb::toRenderable() Returns a render array representation of the object. Return value mixed[] A render array. Overrides RenderableInterface::toRenderable File core/lib/Drupal/Core/Breadcrumb/Breadcrumb.php, line 71 Class Breadcrumb Used to return generated breadcrumbs with associated cacheability metadata. Namespace Drupal\Core\Breadcrumb Code public function toRenderable() { $build = [ '#cache' => [ 'contexts' => $this->cacheContexts, 'tags' =