You are here

interface SearchApiFacetSourceInterface in Facets 8

A facet source that uses Search API as a base.

Hierarchy

Expanded class hierarchy of SearchApiFacetSourceInterface

All classes that implement SearchApiFacetSourceInterface

6 files declare their use of SearchApiFacetSourceInterface
FacetForm.php in src/Form/FacetForm.php
FacetSettingsForm.php in src/Form/FacetSettingsForm.php
FacetsSummarySettingsForm.php in modules/facets_summary/src/Form/FacetsSummarySettingsForm.php
SearchApiBaseFacetSource.php in src/Plugin/facets/facet_source/SearchApiBaseFacetSource.php
SearchApiDisplay.php in src/Plugin/facets/facet_source/SearchApiDisplay.php

... See full list

File

src/FacetSource/SearchApiFacetSourceInterface.php, line 8

Namespace

Drupal\facets\FacetSource
View source
interface SearchApiFacetSourceInterface extends FacetSourcePluginInterface {

  /**
   * Returns the search_api index.
   *
   * @return \Drupal\search_api\IndexInterface
   *   The Search API index.
   */
  public function getIndex();

  /**
   * Retrieves the Search API display plugin associated with this facet source.
   *
   * @return \Drupal\search_api\Display\DisplayInterface
   *   The Search API display plugin associated with this facet source.
   */
  public function getDisplay();

  /**
   * Retrieves the Views entity with the correct display set.
   *
   * This returns NULL when the facet source is not based on views. If it is, it
   * returns a ViewsExecutable plugin with the correct display already set.
   *
   * @return \Drupal\views\ViewExecutable|null
   *   NULL when the view can't be found or loaded, the view with preset display
   *   otherwise.
   */
  public function getViewsDisplay();

}

Members

Namesort descending Modifiers Type Description Overrides
DependentPluginInterface::calculateDependencies public function Calculates dependencies for the configured plugin. 19
FacetSourcePluginInterface::buildFacet public function Builds and returns an extra renderable array for this facet block plugin. 1
FacetSourcePluginInterface::fillFacetsWithResults public function Fills the facet entities with results from the facet source. 1
FacetSourcePluginInterface::getCount public function Returns the number of results that were found for this search. 1
FacetSourcePluginInterface::getDataDefinition public function Returns a single field's data definition from the facet source. 1
FacetSourcePluginInterface::getFields public function Returns an array of fields that are defined on the facet source. 1
FacetSourcePluginInterface::getPath public function Returns the path of the facet source, used to build the facet url. 1
FacetSourcePluginInterface::getQueryTypesForFacet public function Returns the allowed query types for a given facet for the facet source. 1
FacetSourcePluginInterface::getSearchKeys public function Returns the search keys, or query text, submitted by the user. 1
FacetSourcePluginInterface::isRenderedInCurrentRequest public function Returns true if the Facet source is being rendered in the current request. 1
FacetSourcePluginInterface::setSearchKeys public function Sets the search keys, or query text, submitted by the user. 1
PluginFormInterface::buildConfigurationForm public function Form constructor. 36
PluginFormInterface::submitConfigurationForm public function Form submission handler. 32
PluginFormInterface::validateConfigurationForm public function Form validation handler. 18
SearchApiFacetSourceInterface::getDisplay public function Retrieves the Search API display plugin associated with this facet source. 2
SearchApiFacetSourceInterface::getIndex public function Returns the search_api index. 2
SearchApiFacetSourceInterface::getViewsDisplay public function Retrieves the Views entity with the correct display set. 2