public function FacetapiAdapter::__construct in Facet API 7
Same name and namespace in other branches
- 6.3 plugins/facetapi/adapter.inc \FacetapiAdapter::__construct()
- 6 facetapi.adapter.inc \FacetapiAdapter::__construct()
- 7.2 plugins/facetapi/adapter.inc \FacetapiAdapter::__construct()
Constructs a FacetapiAdapter object.
Stores information about the searcher that the adapter is associated with. Registers and instantiates all query type plugins that are associated with the searcher's active facets. Instantiates the url processor plugin associated with this adapter and retrieves facet information from some source, usually $_GET. See the url processor plugin's implementation of FacetapiUrlProcessor::fetchParams() for details on the source containing the facet data.
Parameters
array $searcher_info: The searcher information as returned by facetapi_get_searcher_info().
File
- plugins/
facetapi/ adapter.inc, line 148 - Adapter plugin and adapter related classes.
Class
- FacetapiAdapter
- Abstract class extended by Facet API adapters.
Code
public function __construct(array $searcher_info) {
$this->info = $searcher_info;
// Load and initialize the url processor plugin. Initializing the plugin
// fetches the data from a source, usually $_GET, and trigger the methods
// that instantiate the query type plugins and process the active items.
$this->urlProcessor = $this
->loadUrlProcessor($this->info['url processor']);
$this
->initUrlProcessor();
}