function MenuLinkManager::getDefinition
Same name in other branches
- 9 core/lib/Drupal/Core/Menu/MenuLinkManager.php \Drupal\Core\Menu\MenuLinkManager::getDefinition()
- 8.9.x core/lib/Drupal/Core/Menu/MenuLinkManager.php \Drupal\Core\Menu\MenuLinkManager::getDefinition()
- 11.x core/lib/Drupal/Core/Menu/MenuLinkManager.php \Drupal\Core\Menu\MenuLinkManager::getDefinition()
3 calls to MenuLinkManager::getDefinition()
- MenuLinkManager::getChildIds in core/
lib/ Drupal/ Core/ Menu/ MenuLinkManager.php - MenuLinkManager::getParentIds in core/
lib/ Drupal/ Core/ Menu/ MenuLinkManager.php - MenuLinkManager::hasDefinition in core/
lib/ Drupal/ Core/ Menu/ MenuLinkManager.php
File
-
core/
lib/ Drupal/ Core/ Menu/ MenuLinkManager.php, line 164
Class
- MenuLinkManager
- Manages discovery, instantiation, and tree building of menu link plugins.
Namespace
Drupal\Core\MenuCode
public function getDefinition($plugin_id, $exception_on_invalid = TRUE) {
$definition = $this->treeStorage
->load($plugin_id);
if (empty($definition) && $exception_on_invalid) {
throw new PluginNotFoundException($plugin_id);
}
return $definition;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.