class PathRootsSubscriber implements EventSubscriberInterface (View source)

Provides all available first bits of all route paths.

Properties

protected array $pathRoots

Stores the path roots available in the router.

protected StateInterface $state

The state key value store.

Methods

__construct(StateInterface $state)

Constructs a new PathRootsSubscriber instance.

onRouteAlter(RouteBuildEvent $event)

Collects all path roots.

onRouteFinished()

{@inheritdoc}

static array
getSubscribedEvents()

{@inheritdoc}

Details

__construct(StateInterface $state)

Constructs a new PathRootsSubscriber instance.

Parameters

StateInterface $state

The state key value store.

onRouteAlter(RouteBuildEvent $event)

Collects all path roots.

Parameters

RouteBuildEvent $event

The route build event.

onRouteFinished()

{@inheritdoc}

static array getSubscribedEvents()

{@inheritdoc}

Return Value

array