class MenuRouterRebuildSubscriber implements EventSubscriberInterface (View source)

Rebuilds the default menu links and runs menu-specific code if necessary.

Properties

protected LockBackendInterface $lock
protected MenuLinkManagerInterface $menuLinkManager

The menu link plugin manager.

protected ReplicaKillSwitch $replicaKillSwitch

The replica kill switch.

protected Connection $connection

The database connection.

Methods

__construct(LockBackendInterface $lock, MenuLinkManagerInterface $menu_link_manager, Connection $connection, ReplicaKillSwitch $replica_kill_switch)

Constructs the MenuRouterRebuildSubscriber object.

onRouterRebuild(Event $event)

Rebuilds the menu links and deletes the local_task cache tag.

menuLinksRebuild()

Perform menu-specific rebuilding.

static 
getSubscribedEvents()

{@inheritdoc}

Details

__construct(LockBackendInterface $lock, MenuLinkManagerInterface $menu_link_manager, Connection $connection, ReplicaKillSwitch $replica_kill_switch)

Constructs the MenuRouterRebuildSubscriber object.

Parameters

LockBackendInterface $lock

The lock backend.

MenuLinkManagerInterface $menu_link_manager

The menu link plugin manager.

Connection $connection

The database connection.

ReplicaKillSwitch $replica_kill_switch

The replica kill switch.

onRouterRebuild(Event $event)

Rebuilds the menu links and deletes the local_task cache tag.

Parameters

Event $event

The event object.

protected menuLinksRebuild()

Perform menu-specific rebuilding.

static getSubscribedEvents()

{@inheritdoc}