You are here

public static function ImageEffectsPluginBase::create in Image Effects 8.2

Same name and namespace in other branches
  1. 8.3 src/Plugin/ImageEffectsPluginBase.php \Drupal\image_effects\Plugin\ImageEffectsPluginBase::create()
  2. 8 src/Plugin/ImageEffectsPluginBase.php \Drupal\image_effects\Plugin\ImageEffectsPluginBase::create()

Creates an instance of the plugin.

Parameters

\Symfony\Component\DependencyInjection\ContainerInterface $container: The container to pull out services used in the plugin.

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.

Return value

static Returns an instance of this plugin.

Overrides ContainerFactoryPluginInterface::create

2 methods override ImageEffectsPluginBase::create()
Basic::create in src/Plugin/image_effects/FontSelector/Basic.php
Creates an instance of the plugin.
Dropdown::create in src/Plugin/image_effects/ImageSelector/Dropdown.php
Creates an instance of the plugin.

File

src/Plugin/ImageEffectsPluginBase.php, line 63

Class

ImageEffectsPluginBase
Base image_effects plugin.

Namespace

Drupal\image_effects\Plugin

Code

public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
  return new static($configuration, $plugin_id, $plugin_definition, $container
    ->get('config.factory'), $container
    ->get('logger.channel.image_effects'));
}