12345678910111213141516171819202122232425262728293031 |
- <?php
- namespace Drupal\reinstall\Plugin\migrate\source;
- use Drupal\migrate\Plugin\MigrationInterface;
- /**
- * Source plugin for nodes from a YAML file.
- *
- * @MigrateSource(
- * id = "reinstall_node"
- * )
- */
- class ReinstallNodeSource extends SimpleSource {
- /**
- * Constructor.
- */
- public function __construct(
- array $configuration,
- string $pluginId,
- array $pluginDefinition,
- MigrationInterface $migration
- ) {
- parent::__construct($configuration, $pluginId, $pluginDefinition, $migration);
- $rawRecords = array_map([$this, 'flattenRecord'], $this->initialParse($configuration));
- $this->records = $rawRecords;
- }
- }
|