public function BlockPluginUI::getDerivativeDefinition

Implements \Drupal\Component\Plugin\Derivative\DerivativeInterface::getDerivativeDefinition().

@todo Add documentation to this method.

Overrides DerivativeInterface::getDerivativeDefinition

File

drupal/core/modules/block/lib/Drupal/block/Plugin/Derivative/BlockPluginUI.php, line 32

Class

BlockPluginUI
Provides block plugin UI plugin definitions for all themes.

Namespace

Drupal\block\Plugin\Derivative

Code

public function getDerivativeDefinition($derivative_id, array $base_plugin_definition) {
  if (!empty($this->derivatives) && !empty($this->derivatives[$derivative_id])) {
    return $this->derivatives[$derivative_id];
  }
  $this
    ->getDerivativeDefinitions($base_plugin_definition);
  return $this->derivatives[$derivative_id];
}