function MigrateSource::getProviders

Same name in other branches
  1. 9 core/modules/migrate/src/Annotation/MigrateSource.php \Drupal\migrate\Annotation\MigrateSource::getProviders()
  2. 8.9.x core/modules/migrate/src/Annotation/MigrateSource.php \Drupal\migrate\Annotation\MigrateSource::getProviders()
  3. 10 core/modules/migrate/src/Annotation/MigrateSource.php \Drupal\migrate\Annotation\MigrateSource::getProviders()

Overrides MultipleProviderAnnotationInterface::getProviders

File

core/modules/migrate/src/Annotation/MigrateSource.php, line 81

Class

MigrateSource
Defines a migration source plugin annotation object.

Namespace

Drupal\migrate\Annotation

Code

public function getProviders() {
    if (isset($this->definition['provider'])) {
        // Ensure that we return an array even if
        // \Drupal\Component\Annotation\AnnotationInterface::setProvider() has
        // been called.
        return (array) $this->definition['provider'];
    }
    return [];
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.