You are here

public function ProviderPluginManager::getPlugins in Geocoder 8.3

Same name and namespace in other branches
  1. 8.2 src/ProviderPluginManager.php \Drupal\geocoder\ProviderPluginManager::getPlugins()

Returns the defined plugins.

Note that this method has been changed in Geocoder 3.x. It currently returns the list of plugin definitions which is identical to the list returned by ::getDefinitions().

In Geocoder 2.x this was returning a mix of plugin definitions and configured providers but this architecture has been replaced by the new GeocoderProvider config entity.

It is recommended to no longer use this method but instead use one of these two alternatives:

In order to get a list of all available plugin definitions:

$definitions = \Drupal\geocoder\ProviderPluginManager::getDefinitions();

In order to get a list of all geocoding providers that are configured by the site builder:

$providers = \Drupal\geocoder\Entity\GeocoderProvider::loadMultiple();

Return value

array A list of plugins.

Overrides GeocoderPluginManagerBase::getPlugins

File

src/ProviderPluginManager.php, line 124

Class

ProviderPluginManager
Provides a plugin manager for geocoder providers.

Namespace

Drupal\geocoder

Code

public function getPlugins() : array {
  return $this
    ->getDefinitions();
}