Drupal 8  8.0.2
TestSqlIdMap Class Reference
Inheritance diagram for TestSqlIdMap:

Public Member Functions

 __construct (Connection $database, array $configuration, $plugin_id, $plugin_definition, MigrationInterface $migration, EventDispatcherInterface $event_dispatcher)
 
 getDatabase ()
 
- Public Member Functions inherited from Sql
 __construct (array $configuration, $plugin_id, $plugin_definition, MigrationInterface $migration, EventDispatcherInterface $event_dispatcher)
 
 mapTableName ()
 
 messageTableName ()
 
 getQualifiedMapTableName ()
 
 getDatabase ()
 
 setMessage (MigrateMessageInterface $message)
 
 getRowBySource (array $source_id_values)
 
 getRowByDestination (array $destination_id_values)
 
 getRowsNeedingUpdate ($count)
 
 lookupSourceID (array $destination_id_values)
 
 lookupDestinationId (array $source_id_values)
 
 saveIdMapping (Row $row, array $destination_id_values, $source_row_status=MigrateIdMapInterface::STATUS_IMPORTED, $rollback_action=MigrateIdMapInterface::ROLLBACK_DELETE)
 
 saveMessage (array $source_id_values, $message, $level=MigrationInterface::MESSAGE_ERROR)
 
 getMessageIterator (array $source_id_values=[], $level=NULL)
 
 prepareUpdate ()
 
 processedCount ()
 
 importedCount ()
 
 updateCount ()
 
 errorCount ()
 
 messageCount ()
 
 delete (array $source_id_values, $messages_only=FALSE)
 
 deleteDestination (array $destination_id_values)
 
 setUpdate (array $source_id_values)
 
 clearMessages ()
 
 destroy ()
 
 rewind ()
 
 current ()
 
 key ()
 
 currentDestination ()
 
 next ()
 
 valid ()
 
- Public Member Functions inherited from PluginInspectionInterface
 getPluginId ()
 
 getPluginDefinition ()
 

Protected Member Functions

 getFieldSchema (array $id_definition)
 
- Protected Member Functions inherited from Sql
 sourceIdFields ()
 
 destinationIdFields ()
 
 init ()
 
 ensureTables ()
 
 getFieldSchema (array $id_definition)
 
 countHelper ($status, $table=NULL)
 

Additional Inherited Members

- Static Public Member Functions inherited from Sql
static create (ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition, MigrationInterface $migration=NULL)
 
- Static Public Member Functions inherited from ContainerFactoryPluginInterface
static create (ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition)
 
- Data Fields inherited from MigrateIdMapInterface
const STATUS_IMPORTED = 0
 
const STATUS_NEEDS_UPDATE = 1
 
const STATUS_IGNORED = 2
 
const STATUS_FAILED = 3
 
const ROLLBACK_DELETE = 0
 
const ROLLBACK_PRESERVE = 1
 
- Protected Attributes inherited from Sql
 $eventDispatcher
 
 $mapTableName
 
 $messageTableName
 
 $message
 
 $database
 
 $query
 
 $migration
 
 $sourceIdFields
 
 $destinationIdFields
 
 $initialized
 
 $result = NULL
 
 $sourceIds = array()
 
 $destinationIds = array()
 
 $currentRow = NULL
 
 $currentKey = array()
 

Detailed Description

Defines a SQL ID map for use in tests.

Constructor & Destructor Documentation

__construct ( Connection  $database,
array  $configuration,
  $plugin_id,
  $plugin_definition,
MigrationInterface  $migration,
EventDispatcherInterface  $event_dispatcher 
)

Constructs a TestSqlIdMap object.

Parameters
\Drupal\Core\Database\Connection$databaseThe database.
array$configurationThe configuration.
string$plugin_idThe plugin ID for the migration process to do.
mixed$plugin_definitionThe configuration for the plugin.
\Drupal\migrate\Entity\MigrationInterface$migrationThe migration to do.
\Symfony\Component\EventDispatcher\EventDispatcherInterface$event_dispatcherThe event dispatcher service.

References Drupal\database().

Here is the call graph for this function:

Member Function Documentation

getDatabase ( )

{}

getFieldSchema ( array  $id_definition)
protected

Gets the field schema.

Parameters
array$id_definitionAn array defining the field, with a key 'type'.
Returns
array A field schema depending on value of key 'type'. An empty array is returned if 'type' is not defined.
Exceptions
\Drupal\migrate\MigrateException

The documentation for this class was generated from the following file: