You are here

public function MigrateEntityRevision::getDerivativeDefinitions in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/migrate/src/Plugin/Derivative/MigrateEntityRevision.php \Drupal\migrate\Plugin\Derivative\MigrateEntityRevision::getDerivativeDefinitions()
  2. 9 core/modules/migrate/src/Plugin/Derivative/MigrateEntityRevision.php \Drupal\migrate\Plugin\Derivative\MigrateEntityRevision::getDerivativeDefinitions()

File

core/modules/migrate/src/Plugin/Derivative/MigrateEntityRevision.php, line 57

Class

MigrateEntityRevision

Namespace

Drupal\migrate\Plugin\Derivative

Code

public function getDerivativeDefinitions($base_plugin_definition) {
  foreach ($this->entityDefinitions as $entity_type => $entity_info) {
    if ($entity_info
      ->getKey('revision')) {
      $this->derivatives[$entity_type] = [
        'id' => "entity_revision:{$entity_type}",
        'class' => 'Drupal\\migrate\\Plugin\\migrate\\destination\\EntityRevision',
        'requirements_met' => 1,
        'provider' => $entity_info
          ->getProvider(),
      ];
    }
  }
  return $this->derivatives;
}