Oihana PHP Arango

ArangoAnalyzersTrait

The database-level registry of declared **custom** analyzers, consumed by the `arango:analyzers` action of `command:arangodb` (and signalled by the `doctor`) — the analyzer counterpart of {@see ArangoIndexesTrait}.

Analyzers are immutable, shared and database-scoped (every model/View that names one shares the same server object), so they are declared once here rather than per model. Supplied via the analyzers init key (ArangoCommandParam::ANALYZERS).

The registry is a flat list of AnalyzerDefinition (each carries its own name, options and features). As a convenience a single AnalyzerDefinition is tolerated in place of a one-element list — getAnalyzerDefinitions() normalizes it.

Tags
author

Marc Alcaraz (ekameleon)

since
1.3.0

Table of Contents

Properties

$analyzers  : array<int, AnalyzerDefinition>|AnalyzerDefinition
The declared custom analyzers — a list of {@see AnalyzerDefinition} (a single one is tolerated in place of a one-element list).

Methods

getAnalyzerDefinitions()  : array<int, AnalyzerDefinition>
Returns the declared analyzers normalized to a flat {@see AnalyzerDefinition} list: a lone `AnalyzerDefinition` becomes a one-element list, and any entry that is not an `AnalyzerDefinition` is dropped (defensive against a malformed declaration).

Properties

Methods

getAnalyzerDefinitions()

Returns the declared analyzers normalized to a flat {@see AnalyzerDefinition} list: a lone `AnalyzerDefinition` becomes a one-element list, and any entry that is not an `AnalyzerDefinition` is dropped (defensive against a malformed declaration).

public getAnalyzerDefinitions() : array<int, AnalyzerDefinition>
Return values
array<int, AnalyzerDefinition>
On this page

Search results