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

Breadcrumb

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

function ExecutablePluginBase::getConfigDefinition

Gets the definition of a configuration option.

@todo This needs to go into an interface.

Parameters

string $key: The key of the configuration option to get.

Return value

\Drupal\Core\TypedData\DataDefinitionInterface|false The typed data definition describing the configuration option, or FALSE if the option does not exist.

1 call to ExecutablePluginBase::getConfigDefinition()
ExecutablePluginBase::setConfig in core/lib/Drupal/Core/Executable/ExecutablePluginBase.php
Sets the value of a particular configuration option.

File

core/lib/Drupal/Core/Executable/ExecutablePluginBase.php, line 47

Class

ExecutablePluginBase
Provides the basic architecture for executable plugins.

Namespace

Drupal\Core\Executable

Code

public function getConfigDefinition($key) {
    $definition = $this->getPluginDefinition();
    if (!empty($definition['configuration'][$key])) {
        return $definition['configuration'][$key];
    }
    return FALSE;
}

API Navigation

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