function SectionStorageManager::loadFromStorageId

Loads a section storage populated with an existing section list.

Parameters

string $type: The section storage type.

string $id: The section list ID.

Return value

\Drupal\layout_builder\SectionStorageInterface The section storage.

Overrides SectionStorageManagerInterface::loadFromStorageId

File

core/modules/layout_builder/src/SectionStorage/SectionStorageManager.php, line 117

Class

SectionStorageManager
Provides the Section Storage type plugin manager.

Namespace

Drupal\layout_builder\SectionStorage

Code

public function loadFromStorageId($type, $id) {
    @trigger_error('\\Drupal\\layout_builder\\SectionStorage\\SectionStorageManagerInterface::loadFromStorageId() is deprecated in Drupal 8.7.0 and will be removed before Drupal 9.0.0. \\Drupal\\layout_builder\\SectionStorage\\SectionStorageManagerInterface::load() should be used instead. See https://www.drupal.org/node/3012353.', E_USER_DEPRECATED);
    $contexts = $this->loadEmpty($type)
        ->deriveContextsFromRoute($id, [], '', []);
    return $this->load($type, $contexts);
}

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