Code Coverage |
||||||||||
Classes and Traits |
Functions and Methods |
Lines |
||||||||
Total | |
0.00% |
0 / 1 |
|
0.00% |
0 / 1 |
CRAP | |
0.00% |
0 / 3 |
ConfigImportValidateEventSubscriberBase | |
0.00% |
0 / 1 |
|
50.00% |
1 / 2 |
6 | |
0.00% |
0 / 3 |
onConfigImporterValidate | |
100.00% |
1 / 1 |
1 | |
100.00% |
0 / 0 |
|||
getSubscribedEvents | |
0.00% |
0 / 1 |
2 | |
0.00% |
0 / 3 |
<?php | |
/** | |
* @file | |
* Contains \Drupal\Core\Config\ConfigImportValidateEventSubscriberBase. | |
*/ | |
namespace Drupal\Core\Config; | |
use Drupal\Core\StringTranslation\StringTranslationTrait; | |
use Symfony\Component\EventDispatcher\EventSubscriberInterface; | |
/** | |
* Defines a base event listener implementation for config sync validation. | |
*/ | |
abstract class ConfigImportValidateEventSubscriberBase implements EventSubscriberInterface { | |
use StringTranslationTrait; | |
/** | |
* Checks that the configuration synchronization is valid. | |
* | |
* @param ConfigImporterEvent $event | |
* The config import event. | |
*/ | |
abstract public function onConfigImporterValidate(ConfigImporterEvent $event); | |
/** | |
* {@inheritdoc} | |
*/ | |
static function getSubscribedEvents() { | |
$events[ConfigEvents::IMPORT_VALIDATE][] = array('onConfigImporterValidate', 20); | |
return $events; | |
} | |
} |