You are here

public static function Drupal::menuTree in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/lib/Drupal.php \Drupal::menuTree()

Returns the menu tree.

Return value

\Drupal\Core\Menu\MenuLinkTreeInterface The menu tree.

4 calls to Drupal::menuTree()
AdminTest::getTopLevelMenuLinks in core/modules/system/src/Tests/System/AdminTest.php
Returns all top level menu links.
DrupalTest::testMenuTree in core/tests/Drupal/Tests/Core/DrupalTest.php
Tests the menuTree() method.
MenuLinkContentCacheabilityBubblingTest::testOutboundPathAndRouteProcessing in core/modules/menu_link_content/src/Tests/MenuLinkContentCacheabilityBubblingTest.php
Tests bubbleable metadata of menu links' outbound route/path processing.
system_get_module_admin_tasks in core/modules/system/system.module
Generate a list of tasks offered by a specified module.

File

core/lib/Drupal.php, line 674
Contains \Drupal.

Class

Drupal
Static Service Container wrapper.

Code

public static function menuTree() {
  return static::getContainer()
    ->get('menu.link_tree');
}