You are here

public function ContentEntity::canContainEntityReferences in Search API 8

Determines whether this datasource can contain entity references.

If this method returns TRUE, the Search API will attempt to mark items for reindexing if indexed data in entities referenced by those items changes, using the datasource property information and the getAffectedItemsForEntityChange() method.

Return value

bool TRUE if this datasource can contain entity references, FALSE otherwise.

Overrides DatasourcePluginBase::canContainEntityReferences

See also

\Drupal\search_api\Datasource\DatasourceInterface::getAffectedItemsForEntityChange()

\Drupal\search_api\Utility\TrackingHelper::trackReferencedEntityUpdate()

File

src/Plugin/search_api/datasource/ContentEntity.php, line 1087

Class

ContentEntity
Represents a datasource which exposes the content entities.

Namespace

Drupal\search_api\Plugin\search_api\datasource

Code

public function canContainEntityReferences() : bool {
  return TRUE;
}