function MenuTreeStorage::__construct
Same name in other branches
- 9 core/lib/Drupal/Core/Menu/MenuTreeStorage.php \Drupal\Core\Menu\MenuTreeStorage::__construct()
- 8.9.x core/lib/Drupal/Core/Menu/MenuTreeStorage.php \Drupal\Core\Menu\MenuTreeStorage::__construct()
- 11.x core/lib/Drupal/Core/Menu/MenuTreeStorage.php \Drupal\Core\Menu\MenuTreeStorage::__construct()
Constructs a new \Drupal\Core\Menu\MenuTreeStorage.
Parameters
\Drupal\Core\Database\Connection $connection: A Database connection to use for reading and writing configuration data.
\Drupal\Core\Cache\CacheBackendInterface $menu_cache_backend: Cache backend instance for the extracted tree data.
\Drupal\Core\Cache\CacheTagsInvalidatorInterface $cache_tags_invalidator: The cache tags invalidator.
string $table: A database table name to store configuration data in.
array $options: (optional) Any additional database connection options to use in queries.
1 method overrides MenuTreeStorage::__construct()
- WorkspacesMenuTreeStorage::__construct in core/
modules/ workspaces/ src/ WorkspacesMenuTreeStorage.php - WorkspacesMenuTreeStorage constructor.
File
-
core/
lib/ Drupal/ Core/ Menu/ MenuTreeStorage.php, line 94
Class
- MenuTreeStorage
- Provides a menu tree storage using the database.
Namespace
Drupal\Core\MenuCode
public function __construct(Connection $connection, CacheBackendInterface $menu_cache_backend, CacheTagsInvalidatorInterface $cache_tags_invalidator, $table, array $options = []) {
$this->connection = $connection;
$this->menuCacheBackend = $menu_cache_backend;
$this->cacheTagsInvalidator = $cache_tags_invalidator;
$this->table = $table;
$this->options = $options;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.