You are here

abstract class ConfigImportValidateEventSubscriberBase in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 core/lib/Drupal/Core/Config/ConfigImportValidateEventSubscriberBase.php \Drupal\Core\Config\ConfigImportValidateEventSubscriberBase

Defines a base event listener implementation for config sync validation.

Hierarchy

Expanded class hierarchy of ConfigImportValidateEventSubscriberBase

3 files declare their use of ConfigImportValidateEventSubscriberBase
BundleConfigImportValidate.php in core/lib/Drupal/Core/Entity/Event/BundleConfigImportValidate.php
Contains \Drupal\Core\Entity\Event\BundleConfigImportValidate.
ConfigImportSubscriber.php in core/lib/Drupal/Core/EventSubscriber/ConfigImportSubscriber.php
Contains \Drupal\Core\EventSubscriber\ConfigImportSubscriber.
ConfigSubscriber.php in core/modules/config/src/ConfigSubscriber.php
Contains \Drupal\config\ConfigSubscriber.

File

core/lib/Drupal/Core/Config/ConfigImportValidateEventSubscriberBase.php, line 16
Contains \Drupal\Core\Config\ConfigImportValidateEventSubscriberBase.

Namespace

Drupal\Core\Config
View source
abstract class ConfigImportValidateEventSubscriberBase implements EventSubscriberInterface {
  use StringTranslationTrait;

  /**
   * Checks that the configuration synchronization is valid.
   *
   * @param ConfigImporterEvent $event
   *   The config import event.
   */
  public abstract function onConfigImporterValidate(ConfigImporterEvent $event);

  /**
   * {@inheritdoc}
   */
  static function getSubscribedEvents() {
    $events[ConfigEvents::IMPORT_VALIDATE][] = array(
      'onConfigImporterValidate',
      20,
    );
    return $events;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
ConfigImportValidateEventSubscriberBase::getSubscribedEvents static function Returns an array of event names this subscriber wants to listen to. Overrides EventSubscriberInterface::getSubscribedEvents 1
ConfigImportValidateEventSubscriberBase::onConfigImporterValidate abstract public function Checks that the configuration synchronization is valid. 3
StringTranslationTrait::$stringTranslation protected property The string translation service.
StringTranslationTrait::formatPlural protected function Formats a string containing a count of items.
StringTranslationTrait::getNumberOfPlurals protected function Returns the number of plurals supported by a given language.
StringTranslationTrait::getStringTranslation protected function Gets the string translation service.
StringTranslationTrait::setStringTranslation public function Sets the string translation service to use. 2
StringTranslationTrait::t protected function Translates a string to the current language or to a given language.