Version 1
[yaffs-website] / web / core / modules / migrate_drupal / src / Plugin / migrate / cckfield / CckFieldPluginBase.php
1 <?php
2
3 namespace Drupal\migrate_drupal\Plugin\migrate\cckfield;
4
5 @trigger_error('CckFieldPluginBase is deprecated in Drupal 8.3.x and will be
6 be removed before Drupal 9.0.x. Use \Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase
7 instead.', E_USER_DEPRECATED);
8
9 use Drupal\migrate\Plugin\MigrationInterface;
10 use Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase;
11
12 /**
13  * The base class for all field plugins.
14  *
15  * @deprecated in Drupal 8.3.x, to be removed before Drupal 9.0.x. Use
16  * \Drupal\migrate_drupal\Plugin\migrate\field\FieldPluginBase instead.
17  *
18  * @ingroup migration
19  */
20 abstract class CckFieldPluginBase extends FieldPluginBase {
21
22   /**
23    * Apply any custom processing to the field bundle migrations.
24    *
25    * @param \Drupal\migrate\Plugin\MigrationInterface $migration
26    *   The migration entity.
27    * @param string $field_name
28    *   The field name we're processing the value for.
29    * @param array $data
30    *   The array of field data from FieldValues::fieldData().
31    */
32   public function processFieldValues(MigrationInterface $migration, $field_name, $data) {
33     // Provide a bridge to the old method declared on the interface and now an
34     // abstract method in this class.
35     return $this->processCckFieldValues($migration, $field_name, $data);
36   }
37
38   /**
39    * Apply any custom processing to the field bundle migrations.
40    *
41    * @param \Drupal\migrate\Plugin\MigrationInterface $migration
42    *   The migration entity.
43    * @param string $field_name
44    *   The field name we're processing the value for.
45    * @param array $data
46    *   The array of field data from FieldValues::fieldData().
47    */
48   abstract public function processCckFieldValues(MigrationInterface $migration, $field_name, $data);
49
50 }