public function FieldDiscovery::addAllFieldProcesses in Drupal 8
Same name and namespace in other branches
- 9 core/modules/migrate_drupal/src/FieldDiscovery.php \Drupal\migrate_drupal\FieldDiscovery::addAllFieldProcesses()
Adds the field processes to a migration.
This method is used in field migrations to execute the migration process alter method specified by the 'field_plugin_method' key of the migration for all field plugins applicable to this Drupal to Drupal migration. This method is used internally for field, field instance, widget, and formatter migrations to allow field plugins to alter the process for these migrations.
@internal
Parameters
\Drupal\migrate\Plugin\MigrationInterface $migration: The migration to add process plugins to.
Throws
\InvalidArgumentException
Overrides FieldDiscoveryInterface::addAllFieldProcesses
File
- core/
modules/ migrate_drupal/ src/ FieldDiscovery.php, line 119
Class
- FieldDiscovery
- Provides field discovery for Drupal 6 & 7 migrations.
Namespace
Drupal\migrate_drupalCode
public function addAllFieldProcesses(MigrationInterface $migration) {
$core = $this
->getCoreVersion($migration);
$fields = $this
->getAllFields($core);
foreach ($fields as $entity_type_id => $bundle) {
$this
->addEntityFieldProcesses($migration, $entity_type_id);
}
}