FilterUninstallValidator::__construct

public FilterUninstallValidator::__construct(PluginManagerInterface $filter_manager, EntityManagerInterface $entity_manager, TranslationInterface $string_translation)

Constructs a new FilterUninstallValidator.

Parameters

\Drupal\Component\Plugin\PluginManagerInterface $filter_manager: The filter plugin manager.

\Drupal\Core\Entity\EntityManagerInterface $entity_manager: The entity manager.

\Drupal\Core\StringTranslation\TranslationInterface $string_translation: The string translation service.

File

core/modules/filter/src/FilterUninstallValidator.php, line 42

Class

FilterUninstallValidator
Prevents uninstallation of modules providing used filter plugins.

Namespace

Drupal\filter

Code

public function __construct(PluginManagerInterface $filter_manager, EntityManagerInterface $entity_manager, TranslationInterface $string_translation) {
  $this->filterManager = $filter_manager;
  $this->filterStorage = $entity_manager->getStorage('filter_format');
  $this->stringTranslation = $string_translation;
}
doc_Drupal
2016-10-29 09:14:53
Comments
Leave a Comment

Please login to continue.