You are here

public function MigrateField::__construct in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/migrate_drupal/src/Annotation/MigrateField.php \Drupal\migrate_drupal\Annotation\MigrateField::__construct()

Constructs a Plugin object.

Builds up the plugin definition and invokes the get() method for any classed annotations that were used.

Overrides Plugin::__construct

File

core/modules/migrate_drupal/src/Annotation/MigrateField.php, line 25

Class

MigrateField
Defines a field plugin annotation object.

Namespace

Drupal\migrate_drupal\Annotation

Code

public function __construct($values) {
  parent::__construct($values);

  // Provide default value for core property, in case it's missing.
  if (empty($this->definition['core'])) {
    $this->definition['core'] = [
      6,
    ];
  }
}