Drupal 8  8.0.2
PathBasedBreadcrumbBuilder Class Reference
Inheritance diagram for PathBasedBreadcrumbBuilder:

Public Member Functions

 __construct (RequestContext $context, AccessManagerInterface $access_manager, RequestMatcherInterface $router, InboundPathProcessorInterface $path_processor, ConfigFactoryInterface $config_factory, TitleResolverInterface $title_resolver, AccountInterface $current_user, CurrentPathStack $current_path)
 
 applies (RouteMatchInterface $route_match)
 
 build (RouteMatchInterface $route_match)
 
- Public Member Functions inherited from BreadcrumbBuilderInterface
 applies (RouteMatchInterface $route_match)
 
 build (RouteMatchInterface $route_match)
 

Protected Member Functions

 getRequestForPath ($path, array $exclude)
 

Protected Attributes

 $context
 
 $accessManager
 
 $router
 
 $pathProcessor
 
 $config
 
 $titleResolver
 
 $currentUser
 

Detailed Description

Class to define the menu_link breadcrumb builder.

Constructor & Destructor Documentation

__construct ( RequestContext  $context,
AccessManagerInterface  $access_manager,
RequestMatcherInterface  $router,
InboundPathProcessorInterface  $path_processor,
ConfigFactoryInterface  $config_factory,
TitleResolverInterface  $title_resolver,
AccountInterface  $current_user,
CurrentPathStack  $current_path 
)

Constructs the PathBasedBreadcrumbBuilder.

Parameters
\Drupal\Core\Routing\RequestContext$contextThe router request context.
\Drupal\Core\Access\AccessManagerInterface$access_managerThe menu link access service.
\Symfony\Component\Routing\Matcher\RequestMatcherInterface$routerThe dynamic router service.
\Drupal\Core\PathProcessor\InboundPathProcessorInterface$path_processorThe inbound path processor.
\Drupal\Core\Config\ConfigFactoryInterface$config_factoryThe config factory service.
\Drupal\Core\Controller\TitleResolverInterface$title_resolverThe title resolver service.
\Drupal\Core\Session\AccountInterface$current_userThe current user object.
\Drupal\Core\Path\CurrentPathStack$current_pathThe current path.

References Drupal\accessManager(), Drupal\config(), and Drupal\currentUser().

Here is the call graph for this function:

Member Function Documentation

applies ( RouteMatchInterface  $route_match)

{}

build ( RouteMatchInterface  $route_match)

{}

References Drupal\accessManager(), Drupal\config(), RouteMatch\createFromRequest(), Link\createFromRoute(), Drupal\currentUser(), Url\fromRouteMatch(), PathBasedBreadcrumbBuilder\getRequestForPath(), t(), and Unicode\ucfirst().

Here is the call graph for this function:

getRequestForPath (   $path,
array  $exclude 
)
protected

Matches a path in the router.

Parameters
string$pathThe request path with a leading slash.
array$excludeAn array of paths or system paths to skip.
Returns
A populated request object or NULL if the path couldn't be matched.

Referenced by PathBasedBreadcrumbBuilder\build().

Here is the caller graph for this function:


The documentation for this class was generated from the following file: