Copied!

TermAggregationResult

TermAggregationResult.php : 18
Implements IteratorAggregate, Countable

The base class for all value objects and structs.

Supports read-only properties by marking them as protected. In this case they will only be writable using constructor, and need to be documented using @property-read <type> <$var> annotation in class doc in addition to inline property doc. Writable properties must be public and must be documented inline.

Methods

public__construct()

TermAggregationResult.php : 23

Construct object optionally with a set of properties.

public __construct(string $name[, iterable<string|int, mixed> $entries = [] ])

Readonly properties values must be set using $properties as they aren't writable anymore after object has been created.

Parameters

Name Type Default value Description
$name string - -
$entries iterable<string|int, mixed> [] -

publiccount()

TermAggregationResult.php : 77
public count() : int

Return values

int

publiccreateForAggregation()

TermAggregationResult.php : 93
public static createForAggregation(Aggregation $aggregation[, iterable<string|int, mixed> $entries = [] ]) : self

Parameters

Name Type Default value Description
$aggregation Aggregation - -
$entries iterable<string|int, mixed> [] -

Return values

self

publicgetEntries()

TermAggregationResult.php : 38
public getEntries() : array<string|int, TermAggregationResultEntry>

Return values

array<string|int, TermAggregationResultEntry>

publicgetEntry()

TermAggregationResult.php : 46
public getEntry(object|string|int $key) : TermAggregationResultEntry|null

Parameters

Name Type Default value Description
$key object|string|int - -

Return values

TermAggregationResultEntry|null

publicgetIterator()

TermAggregationResult.php : 82
public getIterator() : Iterator

Return values

Iterator

publicgetKeys()

TermAggregationResult.php : 70

Returns available keys (terms).

public getKeys() : iterable<string|int, object|string|int>

Return values

iterable<string|int, object|string|int>

publicgetName()

AggregationResult.php : 29
public getName() : string

Return values

string

publichasEntry()

TermAggregationResult.php : 60
public hasEntry(object|string|int $key) : bool

Parameters

Name Type Default value Description
$key object|string|int - -

Return values

bool

publicisEmpty()

TermAggregationResult.php : 30
public isEmpty() : bool

Return values

bool

protectedgetProperties()

ValueObject.php : 54

Returns list of available properties' names.

protected getProperties([array<int, string> $dynamicProperties = [] ]) : array<int, string>

Override to add dynamic properties.

Parameters

Name Type Default value Description
$dynamicProperties array<int, string> []

Additional dynamic properties exposed on the object

Return values

array<int, string>

Tags
Serializerignore

()