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

Breadcrumb

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

function ConfigEntityMapper::__construct

Constructs a ConfigEntityMapper.

Parameters

string $plugin_id: The config mapper plugin ID.

mixed $plugin_definition: An array of plugin information as documented in ConfigNamesMapper::__construct() with the following additional keys:

  • entity_type: The name of the entity type this mapper belongs to.

\Drupal\Core\Config\ConfigFactoryInterface $config_factory: The configuration factory.

\Drupal\Core\Config\TypedConfigManagerInterface $typed_config: The typed configuration manager.

\Drupal\locale\LocaleConfigManager $locale_config_manager: The locale configuration manager.

\Drupal\config_translation\ConfigMapperManagerInterface $config_mapper_manager: The mapper plugin discovery service.

\Drupal\Core\Routing\RouteProviderInterface $route_provider: The route provider.

\Drupal\Core\StringTranslation\TranslationInterface $translation_manager: The string translation manager.

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity type manager.

\Drupal\Core\Language\LanguageManagerInterface $language_manager: The language manager.

\Symfony\Contracts\EventDispatcher\EventDispatcherInterface $event_dispatcher: The event dispatcher.

Overrides ConfigNamesMapper::__construct

File

core/modules/config_translation/src/ConfigEntityMapper.php, line 80

Class

ConfigEntityMapper
Configuration mapper for configuration entities.

Namespace

Drupal\config_translation

Code

public function __construct($plugin_id, $plugin_definition, ConfigFactoryInterface $config_factory, TypedConfigManagerInterface $typed_config, LocaleConfigManager $locale_config_manager, ConfigMapperManagerInterface $config_mapper_manager, RouteProviderInterface $route_provider, TranslationInterface $translation_manager, EntityTypeManagerInterface $entity_type_manager, LanguageManagerInterface $language_manager, ?EventDispatcherInterface $event_dispatcher = NULL) {
    parent::__construct($plugin_id, $plugin_definition, $config_factory, $typed_config, $locale_config_manager, $config_mapper_manager, $route_provider, $translation_manager, $language_manager, $event_dispatcher);
    $this->setType($plugin_definition['entity_type']);
    $this->entityTypeManager = $entity_type_manager;
}

API Navigation

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