MenuLinkResetForm

Defines a confirmation form for resetting a single modified menu link. Hierarchy class \Drupal\Core\Form\FormBase implements ContainerInjectionInterface, FormInterface uses DependencySerializationTrait, LoggerChannelTrait, LinkGeneratorTrait, RedirectDestinationTrait, UrlGeneratorTrait, StringTranslationTraitclass \Drupal\Core\Form\ConfirmFormBase implements ConfirmFormInterfaceclass \Drupal\menu_ui\Form\MenuLinkResetForm File core/modules/menu_ui/src/Form/MenuLinkResetForm.php, line 16

MenuLinkManagerInterface::updateDefinition

public MenuLinkManagerInterface::updateDefinition($id, array $new_definition_values, $persist = TRUE) Updates the values for a menu link definition in the menu tree storage. This will update the definition for a discovered menu link without the need for a full rebuild. It is also used for plugins not found through discovery to update definitions. Parameters string $id: The menu link plugin ID. array $new_definition_values: The new values for the link definition. This will usually be just a sub

MenuLinkManagerInterface::resetLink

public MenuLinkManagerInterface::resetLink($id) Resets the values for a menu link based on the values found by discovery. Parameters string $id: The menu link plugin ID. Return value \Drupal\Core\Menu\MenuLinkInterface The menu link instance after being reset. Throws \Drupal\Component\Plugin\Exception\PluginException Thrown if the $id is not a valid, existing, plugin ID or if the link cannot be reset. File core/lib/Drupal/Core/Menu/MenuLinkManagerInterface.php, line 134 Class MenuLinkMan

MenuLinkManagerInterface::resetDefinitions

public MenuLinkManagerInterface::resetDefinitions() Resets any local definition cache. Used for testing. File core/lib/Drupal/Core/Menu/MenuLinkManagerInterface.php, line 193 Class MenuLinkManagerInterface Defines an interface for managing menu links and storing their definitions. Namespace Drupal\Core\Menu Code public function resetDefinitions();

MenuLinkManagerInterface::removeDefinition

public MenuLinkManagerInterface::removeDefinition($id, $persist = TRUE) Removes a single link definition from the menu tree storage. This is used for plugins not found through discovery to remove definitions. Parameters string $id: The menu link plugin ID. bool $persist: If TRUE, this method will attempt to persist the deletion from any external storage by invoking MenuLinkInterface::deleteLink() on the plugin that is being deleted. Throws \Drupal\Component\Plugin\Exception\PluginException Th

MenuLinkManagerInterface::rebuild

public MenuLinkManagerInterface::rebuild() Triggers discovery, save, and cleanup of discovered links. File core/lib/Drupal/Core/Menu/MenuLinkManagerInterface.php, line 28 Class MenuLinkManagerInterface Defines an interface for managing menu links and storing their definitions. Namespace Drupal\Core\Menu Code public function rebuild();

MenuLinkManagerInterface::menuNameInUse

public MenuLinkManagerInterface::menuNameInUse($menu_name) Determines if any links use a given menu name. Parameters string $menu_name: The menu name. Return value bool TRUE if any links are present in the named menu, FALSE otherwise. File core/lib/Drupal/Core/Menu/MenuLinkManagerInterface.php, line 188 Class MenuLinkManagerInterface Defines an interface for managing menu links and storing their definitions. Namespace Drupal\Core\Menu Code public function menuNameInUse($menu_name);

MenuLinkManagerInterface::loadLinksByRoute

public MenuLinkManagerInterface::loadLinksByRoute($route_name, array $route_parameters = array(), $menu_name = NULL) Loads multiple plugin instances based on route. Parameters string $route_name: The route name. array $route_parameters: (optional) The route parameters. Defaults to an empty array. string $menu_name: (optional) Restricts the found links to just those in the named menu. Return value \Drupal\Core\Menu\MenuLinkInterface[] An array of instances keyed by plugin ID. File core/lib/Dru

MenuLinkManagerInterface::getParentIds

public MenuLinkManagerInterface::getParentIds($id) Loads all parent link IDs of a given menu link. This method is very similar to getActiveTrailIds() but allows the link to be specified rather than being discovered based on the menu name and request. This method is mostly useful for testing. Parameters string $id: The menu link plugin ID. Return value array An ordered array of IDs representing the path to the root of the tree. The first element of the array will be equal to $id, unless $id is

MenuLinkManagerInterface::getChildIds

public MenuLinkManagerInterface::getChildIds($id) Loads all child link IDs of a given menu link, regardless of visibility. This method is mostly useful for testing. Parameters string $id: The menu link plugin ID. Return value array An unordered array of IDs representing the IDs of all children, or NULL if the ID is invalid. File core/lib/Drupal/Core/Menu/MenuLinkManagerInterface.php, line 177 Class MenuLinkManagerInterface Defines an interface for managing menu links and storing their de