function ComponentPluginManager::getAllComponents

Same name in this branch
  1. 11.x core/lib/Drupal/Core/Theme/ComponentPluginManager.php \Drupal\Core\Theme\ComponentPluginManager::getAllComponents()
Same name in other branches
  1. 10 core/modules/sdc/src/ComponentPluginManager.php \Drupal\sdc\ComponentPluginManager::getAllComponents()
  2. 10 core/lib/Drupal/Core/Theme/ComponentPluginManager.php \Drupal\Core\Theme\ComponentPluginManager::getAllComponents()

Gets all components.

@internal

Return value

\Drupal\sdc\Plugin\Component[] An array of Component objects.

File

core/modules/sdc/src/ComponentPluginManager.php, line 155

Class

ComponentPluginManager
Defines a plugin manager to deal with sdc.

Namespace

Drupal\sdc

Code

public function getAllComponents() : array {
    $plugin_ids = array_keys($this->getDefinitions());
    return array_values(array_filter(array_map([
        $this,
        'createInstance',
    ], $plugin_ids)));
}

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