You are here

public function SolrDocumentDefinition::setIndexId in Search API Solr 4.x

Same name and namespace in other branches
  1. 8.3 src/TypedData/SolrDocumentDefinition.php \Drupal\search_api_solr\TypedData\SolrDocumentDefinition::setIndexId()

Sets the Search API Index ID.

Parameters

string $index_id: The Server ID to set.

Return value

$this

Overrides SolrDocumentDefinitionInterface::setIndexId

File

src/TypedData/SolrDocumentDefinition.php, line 61

Class

SolrDocumentDefinition
A typed data definition class for describing Solr documents.

Namespace

Drupal\search_api_solr\TypedData

Code

public function setIndexId(string $index_id) {
  return $this
    ->addConstraint('Index', $index_id);
}