public function SearchApiElasticsearchBackend::supportsFeature in Elasticsearch Connector 8
Same name and namespace in other branches
- 8.2 src/Plugin/search_api/backend/SearchApiElasticsearchBackend.php \Drupal\elasticsearch_connector\Plugin\search_api\backend\SearchApiElasticsearchBackend::supportsFeature()
File
- src/
Plugin/ search_api/ backend/ SearchApiElasticsearchBackend.php, line 144 - Contains the SearchApiElasticsearchBackend object.
Class
- SearchApiElasticsearchBackend
- Plugin annotation @SearchApiBackend( id = "elasticsearch", label = @Translation("Elasticsearch"), description = @Translation("Index items using an Elasticsearch server.") )
Namespace
Drupal\elasticsearch_connector\Plugin\search_api\backendCode
public function supportsFeature($feature) {
// First, check the features we always support.
$supported = array(
'search_api_autocomplete',
'search_api_facets',
'search_api_facets_operator_or',
'search_api_grouping',
'search_api_mlt',
);
$supported = array_combine($supported, $supported);
if (isset($supported[$feature])) {
return TRUE;
}
}