function DrupalMediaLibrary::__construct

Same name in other branches
  1. 8.9.x core/modules/media_library/src/Plugin/CKEditorPlugin/DrupalMediaLibrary.php \Drupal\media_library\Plugin\CKEditorPlugin\DrupalMediaLibrary::__construct()

Constructs a new DrupalMediaLibrary plugin object.

Parameters

array $configuration: A configuration array containing information about the plugin instance.

string $plugin_id: The plugin_id for the plugin instance.

array $plugin_definition: The plugin implementation definition.

\Drupal\Core\Extension\ModuleExtensionList $extension_list_module: The module extension list.

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity type manager.

File

core/modules/ckeditor/src/Plugin/CKEditorPlugin/DrupalMediaLibrary.php, line 57

Class

DrupalMediaLibrary
Defines the "drupalmedialibrary" plugin.

Namespace

Drupal\ckeditor\Plugin\CKEditorPlugin

Code

public function __construct(array $configuration, $plugin_id, array $plugin_definition, ModuleExtensionList $extension_list_module, EntityTypeManagerInterface $entity_type_manager) {
    parent::__construct($configuration, $plugin_id, $plugin_definition);
    $this->moduleExtensionList = $extension_list_module;
    $this->mediaTypeStorage = $entity_type_manager->getStorage('media_type');
}

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