![]() |
Antidot PHP API
version 0.16.0
##PHP API to simplify integration of Antidot components
|
Simple AFS facet value representation. More...
Public Member Functions | |
__construct ($label, $key, $count, $meta, $active, $query, $link, $children) | |
Construct new instance. (see class attributes for details) | |
get_meta ($name=null) | |
Retrieves meta data associated to the facet value. | |
format () | |
Retrieve facet element as array. | |
![]() | |
__get ($name) | |
Simple property helper. |
Public Attributes | |
$label = null | |
Label of facet value. | |
$key = null | |
Key of facet value. | |
$count = null | |
Number of elements of facet value. | |
$active = null | |
Boolean state of facet value. | |
$query = null | |
Generated query associated to this facet value. | |
$link = null | |
Generated link from above query. | |
$values = null | |
List of child facet values. |
Simple AFS facet value representation.
format | ( | ) |
Retrieve facet element as array.
All data are store in key => value
format:
label:
label of the facet value, key:
key of the facet value, count:
number of element of the facet value, active:
state of the facet value: true when this facet value is used in current query, false otherwise, query:
query associated to the facet value (see query property for more details), link:
link generated from the query, values:
list of children facet values. This list is not empty for tree facets only. meta:
key-value pairs of meta data identifiers and values.query
and link
is null.get_meta | ( | $name = null | ) |
Retrieves meta data associated to the facet value.
$name | [in] Name of the metadata to retrieve. Default is null which means retrieves all meta data as array of values (keys correspond to meta data name, values correspond to meta data value associated to current facet value). |
OutOfBoundsException | when required meta data name does not exist. |
$active = null |
Boolean state of facet value.
Set to true when current query filters on this facet value.
$query = null |
Generated query associated to this facet value.
When this facet value is active, filter on this facet value is remove from query. If this facet value is inactive, filter on this facet value is added to query.
Added filter replace or complete existing filters depending on facet configuration.
$values = null |
List of child facet values.
This list is usually empty except for tree facets.