public function SearchApiAbstractProcessor::supportsIndex in Search API 7
Check whether this processor is applicable for a certain index.
This can be used for hiding the processor on the index's "Filters" tab. To avoid confusion, you should only use criteria that are immutable, such as the index's item type. Also, since this is only used for UI purposes, you should not completely rely on this to ensure certain index configurations and at least throw an exception with a descriptive error message if this is violated on runtime.
Parameters
SearchApiIndex $index: The index to check for.
Return value
boolean TRUE if the processor can run on the given index; FALSE otherwise.
Overrides SearchApiProcessorInterface::supportsIndex
File
- includes/
processor.inc, line 161 - Contains SearchApiProcessorInterface and SearchApiAbstractProcessor.
Class
- SearchApiAbstractProcessor
- Abstract processor implementation that provides an easy framework for only processing specific fields.
Code
public function supportsIndex(SearchApiIndex $index) {
return TRUE;
}