MigrateEvents.php 1.24 KB
Newer Older
Mike Ryan's avatar
.  
Mike Ryan committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
<?php

namespace Drupal\migrate_plus\Event;

/**
 * Defines the row preparation event for the migration system.
 *
 * @see \Drupal\migrate\Event\MigratePrepareRowEvent
 */
final class MigrateEvents {

  /**
   * Name of the event fired when preparing a source data row.
   *
   * This event allows modules to perform an action whenever the source plugin
   * has read the inital source data into a Row object. Typically, this would be
   * used to add data to the row, manipulate the data into a canonical form, or
   * signal by exception that the row should be skipped. The event listener
19
20
   * method receives a \Drupal\migrate_plus\Event\MigratePrepareRowEvent
   * instance.
Mike Ryan's avatar
.  
Mike Ryan committed
21
22
23
24
25
26
27
28
29
   *
   * @Event
   *
   * @see \Drupal\migrate_plus\Event\MigratePrepareRowEvent
   *
   * @var string
   */
  const PREPARE_ROW = 'migrate_plus.prepare_row';

30
31
32
33
34
35
36
37
38
39
40
41
42
  /**
   * Name of the event fired when a source item is missing.
   *
   * This event allows modules to perform an action whenever a specific item is
   * missing from the source. The event listener method receives a
   * \Drupal\migrate\Event\MigrateRowDeleteEvent instance.
   *
   * @Event
   *
   * @see \Drupal\migrate\Event\MigrateRowDeleteEvent
   */
  const MISSING_SOURCE_ITEM = 'migrate_plus.missing_source_item';

Mike Ryan's avatar
.  
Mike Ryan committed
43
}