You are here

public function MigrateDestinationMenu::prepare in Migrate 7.2

Implementation of MigrateDestination::prepare().

1 call to MigrateDestinationMenu::prepare()
MigrateDestinationMenu::import in plugins/destinations/menu.inc
Import a single row.

File

plugins/destinations/menu.inc, line 111
Support for menu destinations.

Class

MigrateDestinationMenu
Destination class implementing migration into {menu_custom}.

Code

public function prepare($menu, stdClass $row) {

  // We do nothing here but allow child classes to act.
  $migration = Migration::currentMigration();
  $menu->migrate = array(
    'machineName' => $migration
      ->getMachineName(),
  );

  // Call any general handlers.
  migrate_handler_invoke_all('menu', 'prepare', $menu, $row);

  // Then call any prepare handler for this specific Migration.
  if (method_exists($migration, 'prepare')) {
    $migration
      ->prepare($menu, $row);
  }
}