interface EntityDatasourceInterface in Search API 8
Describes an interface for entity datasources.
Hierarchy
- interface \Drupal\search_api\Plugin\HideablePluginInterface; interface \Drupal\Component\Plugin\PluginInspectionInterface; interface \Drupal\Component\Plugin\DerivativeInspectionInterface; interface \Drupal\Component\Plugin\ConfigurableInterface; interface \Drupal\Component\Plugin\DependentPluginInterface; interface \Drupal\Core\Plugin\ContainerFactoryPluginInterface
- interface \Drupal\search_api\Plugin\ConfigurablePluginInterface
- interface \Drupal\search_api\Plugin\IndexPluginInterface
- interface \Drupal\search_api\Datasource\DatasourceInterface
- interface \Drupal\search_api\Plugin\search_api\datasource\EntityDatasourceInterface
- interface \Drupal\search_api\Datasource\DatasourceInterface
- interface \Drupal\search_api\Plugin\IndexPluginInterface
- interface \Drupal\search_api\Plugin\ConfigurablePluginInterface
Expanded class hierarchy of EntityDatasourceInterface
All classes that implement EntityDatasourceInterface
Deprecated
in search_api:8.x-1.16 and is removed from search_api:2.0.0. There is no replacement.
See also
https://www.drupal.org/node/3103584
File
- src/
Plugin/ search_api/ datasource/ EntityDatasourceInterface.php, line 18
Namespace
Drupal\search_api\Plugin\search_api\datasourceView source
interface EntityDatasourceInterface extends DatasourceInterface {
/**
* Retrieves all indexes that are configured to index the given entity.
*
* @param \Drupal\Core\Entity\ContentEntityInterface $entity
* The entity for which to check.
*
* @return \Drupal\search_api\IndexInterface[]
* All indexes that are configured to index the given entity (using this
* datasource class).
*/
public static function getIndexesForEntity(ContentEntityInterface $entity);
/**
* Retrieves all item IDs of entities of the specified bundles.
*
* @param int|null $page
* The zero-based page of IDs to retrieve, for the paging mechanism
* implemented by this datasource; or NULL to retrieve all items at once.
* @param string[]|null $bundles
* (optional) The bundles for which all item IDs should be returned; or NULL
* to retrieve IDs from all enabled bundles in this datasource.
* @param string[]|null $languages
* (optional) The languages for which all item IDs should be returned; or
* NULL to retrieve IDs from all enabled languages in this datasource.
*
* @return string[]|null
* An array of all item IDs matching these conditions; or NULL if a page was
* specified and there are no more items for that and all following pages.
* In case both bundles and languages are specified, they are combined with
* OR.
*/
public function getPartialItemIds($page = NULL, array $bundles = NULL, array $languages = NULL);
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ConfigurableInterface:: |
public | function | Gets default configuration for this plugin. | 11 |
ConfigurableInterface:: |
public | function | Gets this plugin's configuration. | 12 |
ConfigurableInterface:: |
public | function | Sets the configuration for this plugin instance. | 12 |
ConfigurablePluginInterface:: |
public | function | Returns the plugin's description. | 1 |
ConfigurablePluginInterface:: |
public | function | Returns the label for use on the administration pages. | 1 |
ConfigurablePluginInterface:: |
public | function | Informs the plugin that some of its dependencies are being removed. | 1 |
ContainerFactoryPluginInterface:: |
public static | function | Creates an instance of the plugin. | 112 |
DatasourceInterface:: |
public | function | Determines whether this datasource can contain entity references. | 1 |
DatasourceInterface:: |
public | function | Checks whether a user has permission to view the given item. | 1 |
DatasourceInterface:: |
public | function | Identifies items affected by a change to a referenced entity. | 1 |
DatasourceInterface:: |
public | function | Retrieves the bundles associated to this datasource. | 1 |
DatasourceInterface:: |
public | function | Retrieves the entity type ID of items from this datasource, if any. | 1 |
DatasourceInterface:: |
public | function | Retrieves any dependencies of the given fields. | 1 |
DatasourceInterface:: |
public | function | Checks whether a user has permission to view the given item. | 1 |
DatasourceInterface:: |
public | function | Retrieves the item's bundle. | 1 |
DatasourceInterface:: |
public | function | Retrieves the unique ID of an object from this datasource. | 3 |
DatasourceInterface:: |
public | function | Returns a list of IDs of items from this datasource. | 1 |
DatasourceInterface:: |
public | function | Retrieves a human-readable label for an item. | 1 |
DatasourceInterface:: |
public | function | Retrieves the item's language. | 1 |
DatasourceInterface:: |
public | function | Retrieves a URL at which the item can be viewed on the web. | 1 |
DatasourceInterface:: |
public | function | Returns the list cache contexts associated with this datasource. | 1 |
DatasourceInterface:: |
public | function | Retrieves the properties exposed by the underlying complex data type. | 1 |
DatasourceInterface:: |
public | function | Returns the available view modes for this datasource. | 1 |
DatasourceInterface:: |
public | function | Loads an item. | 1 |
DatasourceInterface:: |
public | function | Loads multiple items. | 1 |
DatasourceInterface:: |
public | function | Returns the render array for the provided item and view mode. | 1 |
DatasourceInterface:: |
public | function | Returns the render array for the provided items and view mode. | 1 |
DependentPluginInterface:: |
public | function | Calculates dependencies for the configured plugin. | 19 |
DerivativeInspectionInterface:: |
public | function | Gets the base_plugin_id of the plugin instance. | 1 |
DerivativeInspectionInterface:: |
public | function | Gets the derivative_id of the plugin instance. | 1 |
EntityDatasourceInterface:: |
public static | function | Retrieves all indexes that are configured to index the given entity. | |
EntityDatasourceInterface:: |
public | function | Retrieves all item IDs of entities of the specified bundles. | |
HideablePluginInterface:: |
public | function | Determines whether this plugin should be hidden in the UI. | 1 |
IndexPluginInterface:: |
public | function | Retrieves the index this plugin is configured for. | 1 |
IndexPluginInterface:: |
public | function | Sets the index this plugin is configured for. | 1 |
PluginInspectionInterface:: |
public | function | Gets the definition of the plugin implementation. | 4 |
PluginInspectionInterface:: |
public | function | Gets the plugin_id of the plugin instance. | 2 |