You are here

protected function ColorsSchemePluginCollection::initializePlugin in Colors 8

Initializes and stores a plugin.

Parameters

string $instance_id: The ID of the plugin instance to initialize.

Overrides DefaultLazyPluginCollection::initializePlugin

File

src/Plugin/ColorsSchemePluginCollection.php, line 36

Class

ColorsSchemePluginCollection

Namespace

Drupal\colors\Plugin

Code

protected function initializePlugin($plugin_id) {
  if (isset($this->pluginInstances[$plugin_id])) {
    return;
  }
  $this->pluginInstances[$plugin_id] = $this->manager
    ->createInstance($plugin_id, array());
}