PrepareFacetsOnlyTrait
Prepares the `facetsOnly` flag of a list query.
Superseded by PrepareMetaOnlyTrait (?metaOnly=), which
also keeps the numeric bounds. ?facetsOnly= stays a truthy alias
of ?metaOnly=; the controller ORs the two flags.
Driven by ?facetsOnly=true (any filter_var() boolean form: true,
1, yes, on). When truthy, the controller skips the document-fetch query
entirely: the list returns an empty result set, while an exact total (from
DocumentsCountTrait::count()) and,
when ?facetCounts=… is also present, the per-value facet counts are still
returned. This is the "counts sidebar without the documents" mode.
Tags
Table of Contents
Methods
- prepareFacetsOnly() : bool
- Resolves the `facetsOnly` flag for a list query.
Methods
prepareFacetsOnly()
Resolves the `facetsOnly` flag for a list query.
protected
prepareFacetsOnly(ServerRequestInterface|null $request[, array<string|int, mixed> $args = [] ][, array<string|int, mixed>|null &$params = null ]) : bool
Parameters
- $request : ServerRequestInterface|null
-
The HTTP request.
- $args : array<string|int, mixed> = []
-
Predefined options (
$args[Arango::FACETS_ONLY]as base). - $params : array<string|int, mixed>|null = null
-
Echoed query params, populated by reference.
Return values
bool —True when only the counts (no documents) are requested.