3 namespace Drupal\migrate_drupal\Annotation;
5 use Drupal\Component\Annotation\Plugin;
8 * Defines a field plugin annotation object.
10 * Field plugins are responsible for handling the migration of custom fields
11 * (provided by CCK in Drupal 6 and Field API in Drupal 7) to Drupal 8. They are
12 * allowed to alter fieldable entity migrations when these migrations are being
13 * generated, and can compute destination field types for individual fields
14 * during the actual migration process.
16 * Plugin Namespace: Plugin\migrate\field
20 class MigrateField extends Plugin {
25 public function __construct($values) {
26 parent::__construct($values);
27 // Provide default value for core property, in case it's missing.
28 if (empty($this->definition['core'])) {
29 $this->definition['core'] = [6];
41 * Map of D6 and D7 field types to D8 field type plugin IDs.
45 public $type_map = [];
48 * The Drupal core version(s) this plugin applies to.