protected function FieldLayoutEntityDisplayTrait::doGetLayout in Drupal 10
Same name and namespace in other branches
- 8 core/modules/field_layout/src/Entity/FieldLayoutEntityDisplayTrait.php \Drupal\field_layout\Entity\FieldLayoutEntityDisplayTrait::doGetLayout()
- 9 core/modules/field_layout/src/Entity/FieldLayoutEntityDisplayTrait.php \Drupal\field_layout\Entity\FieldLayoutEntityDisplayTrait::doGetLayout()
Gets the layout plugin.
Parameters
string $layout_id: A layout plugin ID.
array $layout_settings: An array of settings.
Return value
\Drupal\Core\Layout\LayoutInterface The layout plugin.
File
- core/
modules/ field_layout/ src/ Entity/ FieldLayoutEntityDisplayTrait.php, line 98
Class
- FieldLayoutEntityDisplayTrait
- Provides shared code for entity displays.
Namespace
Drupal\field_layout\EntityCode
protected function doGetLayout($layout_id, array $layout_settings) {
return \Drupal::service('plugin.manager.core.layout')
->createInstance($layout_id, $layout_settings);
}