You are here

protected function IndexTaskManager::getTaskConditions in Search API 8

Gets a set of conditions for finding the tracking tasks of the given index.

Parameters

\Drupal\search_api\IndexInterface $index: The index for which to retrieve tasks.

Return value

array An array of conditions to pass to the Search API task manager.

5 calls to IndexTaskManager::getTaskConditions()
IndexTaskManager::addItemsAll in src/Task/IndexTaskManager.php
Tracks all remaining items for the given index.
IndexTaskManager::addItemsBatch in src/Task/IndexTaskManager.php
Sets a batch to track all remaining items for the given index.
IndexTaskManager::addItemsOnce in src/Task/IndexTaskManager.php
Adds a single page of items to the tracker.
IndexTaskManager::isTrackingComplete in src/Task/IndexTaskManager.php
Checks whether tracking has already been completed for the given index.
IndexTaskManager::stopTracking in src/Task/IndexTaskManager.php
Stops tracking for the given index.

File

src/Task/IndexTaskManager.php, line 187

Class

IndexTaskManager
Provides a service for managing pending index tasks.

Namespace

Drupal\search_api\Task

Code

protected function getTaskConditions(IndexInterface $index) {
  return [
    'type' => self::TRACK_ITEMS_TASK_TYPE,
    'index_id' => $index
      ->id(),
  ];
}