function BookManager::bookTreeGetFlat

Same name in this branch
  1. 10 core/modules/book/src/BookManager.php \Drupal\book\BookManager::bookTreeGetFlat()
Same name and namespace in other branches
  1. 9 core/modules/book/src/BookManager.php \Drupal\book\BookManager::bookTreeGetFlat()
  2. 8.9.x core/modules/book/src/BookManager.php \Drupal\book\BookManager::bookTreeGetFlat()
  3. 11.x core/modules/book/src/ProxyClass/BookManager.php \Drupal\book\ProxyClass\BookManager::bookTreeGetFlat()
  4. 11.x core/modules/book/src/BookManager.php \Drupal\book\BookManager::bookTreeGetFlat()

Gets the book for a page and returns it as a linear array.

Parameters

array $book_link: A fully loaded book link that is part of the book hierarchy.

Return value

array A linear array of book links in the order that the links are shown in the book, so the previous and next pages are the elements before and after the element corresponding to the current node. The children of the current node (if any) will come immediately after it in the array, and links will only be fetched as deep as one level deeper than $book_link.

Overrides BookManagerInterface::bookTreeGetFlat

File

core/modules/book/src/ProxyClass/BookManager.php, line 179

Class

BookManager
Provides a proxy class for \Drupal\book\BookManager.

Namespace

Drupal\book\ProxyClass

Code

public function bookTreeGetFlat(array $book_link) {
  return $this->lazyLoadItself()
    ->bookTreeGetFlat($book_link);
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.