You are here

public function Library::__construct in Layout builder library 8

Constructs a new Library object.

Parameters

array $configuration: Configuration.

string $plugin_id: ID.

mixed $plugin_definition: Definition.

\Drupal\Core\Entity\EntityTypeManagerInterface $entityTypeManager: Entity type manager.

\Drupal\layout_builder\Entity\LayoutBuilderSampleEntityGenerator $sampleEntityGenerator: Sample entity generator.

Overrides ContextAwarePluginBase::__construct

File

src/Plugin/SectionStorage/Library.php, line 69

Class

Library
Defines a class for library based layout storage.

Namespace

Drupal\layout_library\Plugin\SectionStorage

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition, EntityTypeManagerInterface $entityTypeManager, LayoutBuilderSampleEntityGenerator $sampleEntityGenerator) {
  parent::__construct($configuration, $plugin_id, $plugin_definition);
  $this->entityTypeManager = $entityTypeManager;
  $this->sampleEntityGenerator = $sampleEntityGenerator;
}