You are here

public function Http::getAuthenticationPlugin in Migrate Plus 8.3

Same name and namespace in other branches
  1. 8.5 src/Plugin/migrate_plus/data_fetcher/Http.php \Drupal\migrate_plus\Plugin\migrate_plus\data_fetcher\Http::getAuthenticationPlugin()
  2. 8.2 src/Plugin/migrate_plus/data_fetcher/Http.php \Drupal\migrate_plus\Plugin\migrate_plus\data_fetcher\Http::getAuthenticationPlugin()
  3. 8.4 src/Plugin/migrate_plus/data_fetcher/Http.php \Drupal\migrate_plus\Plugin\migrate_plus\data_fetcher\Http::getAuthenticationPlugin()

Returns the initialized authentication plugin.

Return value

\Drupal\migrate_plus\AuthenticationPluginInterface The authentication plugin.

File

src/Plugin/migrate_plus/data_fetcher/Http.php, line 55

Class

Http
Retrieve data over an HTTP connection for migration.

Namespace

Drupal\migrate_plus\Plugin\migrate_plus\data_fetcher

Code

public function getAuthenticationPlugin() {
  if (!isset($this->authenticationPlugin)) {
    $this->authenticationPlugin = \Drupal::service('plugin.manager.migrate_plus.authentication')
      ->createInstance($this->configuration['authentication']['plugin'], $this->configuration['authentication']);
  }
  return $this->authenticationPlugin;
}