You are here

public static function PluginEventSubscriber::getSubscribedEvents in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/migrate/src/Plugin/PluginEventSubscriber.php \Drupal\migrate\Plugin\PluginEventSubscriber::getSubscribedEvents()
  2. 10 core/modules/migrate/src/Plugin/PluginEventSubscriber.php \Drupal\migrate\Plugin\PluginEventSubscriber::getSubscribedEvents()

File

core/modules/migrate/src/Plugin/PluginEventSubscriber.php, line 84

Class

PluginEventSubscriber
Event subscriber to forward Migrate events to source and destination plugins.

Namespace

Drupal\migrate\Plugin

Code

public static function getSubscribedEvents() {
  $events = [];
  $events[MigrateEvents::PRE_IMPORT][] = [
    'preImport',
  ];
  $events[MigrateEvents::POST_IMPORT][] = [
    'postImport',
  ];
  $events[MigrateEvents::PRE_ROLLBACK][] = [
    'preRollback',
  ];
  $events[MigrateEvents::POST_ROLLBACK][] = [
    'postRollback',
  ];
  return $events;
}