Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Image.php

function Image::__construct

Same name in this branch
  1. 11.1.x vendor/symfony/validator/Constraints/Image.php \Symfony\Component\Validator\Constraints\Image::__construct()
  2. 11.1.x vendor/symfony/dom-crawler/Image.php \Symfony\Component\DomCrawler\Image::__construct()
  3. 11.1.x core/lib/Drupal/Core/Image/Image.php \Drupal\Core\Image\Image::__construct()

Constructs a new class instance.

Parameters

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

string $plugin_id: The plugin ID for the plugin instance.

mixed $plugin_definition: The plugin implementation definition.

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: Entity type manager service.

\Drupal\Core\Entity\EntityFieldManagerInterface $entity_field_manager: Entity field manager service.

\Drupal\Core\Field\FieldTypePluginManagerInterface $field_type_manager: The field type plugin manager service.

\Drupal\Core\Config\ConfigFactoryInterface $config_factory: The config factory service.

\Drupal\Core\Image\ImageFactory $image_factory: The image factory.

\Drupal\Core\File\FileSystemInterface $file_system: The file system service.

Overrides MediaSourceBase::__construct

File

core/modules/media/src/Plugin/media/Source/Image.php, line 83

Class

Image
Image entity media source.

Namespace

Drupal\media\Plugin\media\Source

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition, EntityTypeManagerInterface $entity_type_manager, EntityFieldManagerInterface $entity_field_manager, FieldTypePluginManagerInterface $field_type_manager, ConfigFactoryInterface $config_factory, ImageFactory $image_factory, FileSystemInterface $file_system) {
    parent::__construct($configuration, $plugin_id, $plugin_definition, $entity_type_manager, $entity_field_manager, $field_type_manager, $config_factory);
    $this->imageFactory = $image_factory;
    $this->fileSystem = $file_system;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal