protected function MenuTreeStorage::doBuildTreeData in Drupal 10
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/Menu/MenuTreeStorage.php \Drupal\Core\Menu\MenuTreeStorage::doBuildTreeData()
- 9 core/lib/Drupal/Core/Menu/MenuTreeStorage.php \Drupal\Core\Menu\MenuTreeStorage::doBuildTreeData()
Prepares the data for calling $this->treeDataRecursive().
File
- core/
lib/ Drupal/ Core/ Menu/ MenuTreeStorage.php, line 1098
Class
- MenuTreeStorage
- Provides a menu tree storage using the database.
Namespace
Drupal\Core\MenuCode
protected function doBuildTreeData(array $links, array $parents = [], $depth = 1) {
// Reverse the array so we can use the more efficient array_pop() function.
$links = array_reverse($links);
return $this
->treeDataRecursive($links, $parents, $depth);
}