NumericRangeSearchFacet
in package
implements
JsonSerializable, SearchFacet
A facet that categorizes hits into numerical ranges (or buckets) provided by the user.
Interfaces, Classes, Traits and Enums
- JsonSerializable
- SearchFacet
- Common interface for all search facets
Table of Contents
- $field : string
- $ranges : array<string|int, mixed>
- $size : int
- __construct() : mixed
- addRange() : NumericRangeSearchFacet
- jsonSerialize() : mixed
Properties
$field
private
string
$field
$ranges
private
array<string|int, mixed>
$ranges
= []
$size
private
int
$size
Methods
__construct()
public
__construct(string $field, int $limit) : mixed
Parameters
- $field : string
- $limit : int
Return values
mixed —addRange()
public
addRange(string $name[, float|null $min = null ][, float|null $max = null ]) : NumericRangeSearchFacet
Parameters
- $name : string
- $min : float|null = null
- $max : float|null = null
Tags
Return values
NumericRangeSearchFacet —jsonSerialize()
public
jsonSerialize() : mixed