interface TypedConfigManagerInterface

Same name in other branches
  1. 8.9.x core/lib/Drupal/Core/Config/TypedConfigManagerInterface.php \Drupal\Core\Config\TypedConfigManagerInterface
  2. 10 core/lib/Drupal/Core/Config/TypedConfigManagerInterface.php \Drupal\Core\Config\TypedConfigManagerInterface
  3. 11.x core/lib/Drupal/Core/Config/TypedConfigManagerInterface.php \Drupal\Core\Config\TypedConfigManagerInterface

Defines an interface for managing config schema type plugins.

Hierarchy

  • interface \Drupal\Component\Plugin\Discovery\CachedDiscoveryInterface extends \Drupal\Component\Plugin\Discovery\DiscoveryInterface; interface \Drupal\Component\Plugin\PluginManagerInterface extends \Drupal\Component\Plugin\Discovery\DiscoveryInterface \Drupal\Component\Plugin\Factory\FactoryInterface \Drupal\Component\Plugin\Mapper\MapperInterface
    • interface \Drupal\Core\TypedData\TypedDataManagerInterface extends \Drupal\Component\Plugin\PluginManagerInterface \Drupal\Component\Plugin\Discovery\CachedDiscoveryInterface

Expanded class hierarchy of TypedConfigManagerInterface

All classes that implement TypedConfigManagerInterface

See also

\Drupal\Core\Config\TypedConfigManager

\Drupal\Core\Config\Schema\ConfigSchemaDiscovery

hook_config_schema_info_alter()

https://www.drupal.org/node/1905070

19 files declare their use of TypedConfigManagerInterface
CKEditor5MediaAndFilterSettingsInSyncConstraintValidator.php in core/modules/ckeditor5/src/Plugin/Validation/Constraint/CKEditor5MediaAndFilterSettingsInSyncConstraintValidator.php
CKEditor5PluginDefinition.php in core/modules/ckeditor5/src/Plugin/CKEditor5PluginDefinition.php
ConfigEntityAdapter.php in core/lib/Drupal/Core/Entity/Plugin/DataType/ConfigEntityAdapter.php
ConfigEntityMapper.php in core/modules/config_translation/src/ConfigEntityMapper.php
ConfigEntityStorageTest.php in core/tests/Drupal/Tests/Core/Config/Entity/ConfigEntityStorageTest.php

... See full list

File

core/lib/Drupal/Core/Config/TypedConfigManagerInterface.php, line 15

Namespace

Drupal\Core\Config
View source
interface TypedConfigManagerInterface extends TypedDataManagerInterface {
    
    /**
     * Gets typed configuration data.
     *
     * @param string $name
     *   Configuration object name.
     *
     * @return \Drupal\Core\TypedData\TraversableTypedDataInterface
     *   Typed configuration element.
     */
    public function get($name);
    
    /**
     * Creates a new data definition object.
     *
     * Since type definitions may contain variables to be replaced, we need the
     * configuration value to create it.
     *
     * @param array $definition
     *   The base type definition array, for which a data definition should be
     *   created.
     * @param $value
     *   Optional value of the configuration element.
     * @param string $name
     *   Optional name of the configuration element.
     * @param object $parent
     *   Optional parent element.
     *
     * @return \Drupal\Core\TypedData\DataDefinitionInterface
     *   A data definition for the given data type.
     */
    public function buildDataDefinition(array $definition, $value, $name = NULL, $parent = NULL);
    
    /**
     * Checks if the configuration schema with the given config name exists.
     *
     * @param string $name
     *   Configuration name.
     *
     * @return bool
     *   TRUE if configuration schema exists, FALSE otherwise.
     */
    public function hasConfigSchema($name);
    
    /**
     * Gets a specific plugin definition.
     *
     * @param string $plugin_id
     *   A plugin id.
     * @param bool $exception_on_invalid
     *   Ignored with TypedConfigManagerInterface. Kept for compatibility with
     *   DiscoveryInterface.
     *
     * @return array
     *   A plugin definition array. If the given plugin id does not have typed
     *   configuration definition assigned, the definition of an undefined
     *   element type is returned.
     */
    public function getDefinition($plugin_id, $exception_on_invalid = TRUE);
    
    /**
     * Gets typed data for a given configuration name and its values.
     *
     * @param string $config_name
     *   The machine name of the configuration.
     * @param array $config_data
     *   The data associated with the configuration. Note: This configuration
     *   doesn't yet have to be stored.
     *
     * @return \Drupal\Core\TypedData\TraversableTypedDataInterface
     *   The typed configuration element.
     */
    public function createFromNameAndData($config_name, array $config_data);

}

Members

Title Sort descending Modifiers Object type Summary Overriden Title Overrides
CachedDiscoveryInterface::clearCachedDefinitions public function Clears static and persistent plugin definition caches. 1
CachedDiscoveryInterface::useCaches public function Disable the use of caches. 1
DiscoveryInterface::getDefinitions public function Gets the definition of all plugins for this type. 1
DiscoveryInterface::hasDefinition public function Indicates if a specific plugin definition exists.
TypedConfigManagerInterface::buildDataDefinition public function Creates a new data definition object. 1
TypedConfigManagerInterface::createFromNameAndData public function Gets typed data for a given configuration name and its values. 1
TypedConfigManagerInterface::get public function Gets typed configuration data. 1
TypedConfigManagerInterface::getDefinition public function Gets a specific plugin definition. Overrides DiscoveryInterface::getDefinition
TypedConfigManagerInterface::hasConfigSchema public function Checks if the configuration schema with the given config name exists. 1
TypedDataManagerInterface::create public function Creates a new typed data object instance. 1
TypedDataManagerInterface::createDataDefinition public function Creates a new data definition object. 1
TypedDataManagerInterface::createInstance public function Instantiates a typed data object.
TypedDataManagerInterface::createListDataDefinition public function Creates a new list data definition for items of the given data type. 1
TypedDataManagerInterface::getCanonicalRepresentation public function Gets the canonical representation of a TypedData object. 1
TypedDataManagerInterface::getDefaultConstraints public function Gets default constraints for the given data definition. 1
TypedDataManagerInterface::getInstance public function
TypedDataManagerInterface::getPropertyInstance public function Get a typed data instance for a property of a given typed data object. 1
TypedDataManagerInterface::getValidationConstraintManager public function Gets the validation constraint manager. 1
TypedDataManagerInterface::getValidator public function Gets the validator for validating typed data. 1
TypedDataManagerInterface::setValidationConstraintManager public function Sets the validation constraint manager. 1
TypedDataManagerInterface::setValidator public function Sets the validator for validating typed data. 1

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.