public function ParseModePluginManager::getInstances in Search API 8
Returns all known parse modes.
Return value
\Drupal\search_api\ParseMode\ParseModeInterface[] An array of parse mode plugins, keyed by type identifier.
1 call to ParseModePluginManager::getInstances()
- ParseModePluginManager::getInstancesOptions in src/
ParseMode/ ParseModePluginManager.php - Returns all parse modes known by the Search API as an options list.
File
- src/
ParseMode/ ParseModePluginManager.php, line 48
Class
- ParseModePluginManager
- Manages parse mode plugins.
Namespace
Drupal\search_api\ParseModeCode
public function getInstances() {
$parse_modes = [];
foreach ($this
->getDefinitions() as $plugin_id => $definition) {
if (class_exists($definition['class'])) {
$parse_modes[$plugin_id] = $this
->createInstance($plugin_id);
}
}
return $parse_modes;
}