You are here

public function SearchApiElasticsearchBackend::getSupportedDataTypes in Elasticsearch Connector 8.6

Same name and namespace in other branches
  1. 8.7 src/Plugin/search_api/backend/SearchApiElasticsearchBackend.php \Drupal\elasticsearch_connector\Plugin\search_api\backend\SearchApiElasticsearchBackend::getSupportedDataTypes()

Get a list of supported data types.

Return value

array Returns an array of strings representing supported data types.

Overrides SearchApiElasticsearchBackendInterface::getSupportedDataTypes

1 call to SearchApiElasticsearchBackend::getSupportedDataTypes()
SearchApiElasticsearchBackend::supportsDataType in src/Plugin/search_api/backend/SearchApiElasticsearchBackend.php
Determines whether the backend supports a given add-on data type.

File

src/Plugin/search_api/backend/SearchApiElasticsearchBackend.php, line 331

Class

SearchApiElasticsearchBackend
Elasticsearch Search API Backend definition.

Namespace

Drupal\elasticsearch_connector\Plugin\search_api\backend

Code

public function getSupportedDataTypes() {
  $data_types = [
    'object',
    'location',
  ];

  // Allow other modules to intercept and define what types they want to
  // support.
  $this->moduleHandler
    ->alter('elasticsearch_connector_supported_data_types', $data_types);
  return $data_types;
}