AqlQuery
Read onlyYes
Immutable representation of an AQL query and its bind parameters.
Instances are typically obtained through the aql() helper (which
produces them from a string template + variadic values), or constructed
directly when the caller already holds a (query, bindVars) pair — for
example when the query was assembled by a query builder.
Example:
// Built via the aql() helper:
$query = aql( 'FOR u IN users FILTER u.age > ? RETURN u' , 18 ) ;
// Or built directly (typical for query-builder output):
$query = new AqlQuery
(
'FOR u IN users FILTER u.age > @minAge RETURN u' ,
[ 'minAge' => 18 ] ,
) ;
Tags
Table of Contents
Properties
Methods
- __construct() : mixed
Properties
$bindVars
public
array<string|int, mixed>
$bindVars
= []
$query
public
string
$query
Methods
__construct()
public
__construct(string $query[, array<string, mixed> $bindVars = [] ]) : mixed
Parameters
- $query : string
-
Raw AQL query string. Bind references use ArangoDB's
@name(values) or@@name(collections) syntax. - $bindVars : array<string, mixed> = []
-
Map of bind name → value (without the leading
@).