conditions
Table of Contents
Functions
- isAdditionalType() : array<string|int, mixed>
- Filter documents by additionalType schema.
- isProperty() : array<string|int, mixed>
- Build an AQL equality condition on a document property.
- isSchemaType() : array<string|int, mixed>
- Filter documents by the canonical schema type of a Thing class.
Functions
isAdditionalType()
Filter documents by additionalType schema.
isAdditionalType(string|array<string|int, mixed> $schemaType[, string $docRef = AQL::DOC ]) : array<string|int, mixed>
Accepts a string, an AQL expression, or an array of values.
Parameters
- $schemaType : string|array<string|int, mixed>
-
The schema type(s) to filter by
- $docRef : string = AQL::DOC
-
The AQL doc reference (default: doc)
Tags
Return values
array<string|int, mixed> —An array containing a single AQL condition expression
isProperty()
Build an AQL equality condition on a document property.
isProperty(string $property, null|string|array<string|int, mixed> $value[, string $docRef = AQL::DOC ]) : array<string|int, mixed>
This helper creates an equality condition (==) when a scalar value or
AQL expression is provided, and an IN condition when an array of values
is given.
Parameters
- $property : string
-
The property name (Prop::*)
- $value : null|string|array<string|int, mixed>
-
The expected value or expression.
- $docRef : string = AQL::DOC
-
The AQL doc reference (default: doc)
Tags
Return values
array<string|int, mixed> —An array containing a single AQL condition expression
isSchemaType()
Filter documents by the canonical schema type of a Thing class.
isSchemaType(Thing>|array<string|int, Thing>> $class[, string $docRef = AQL::DOC ]) : array<string|int, mixed>
Resolves the absolute type URI of the given class — its CONTEXT plus its short name, see Thing::getSchemaType() — and delegates to isAdditionalType(). Accepts several classes for an IN condition.
Parameters
- $class : Thing>|array<string|int, Thing>>
-
The Thing class(es) to filter by.
- $docRef : string = AQL::DOC
-
The AQL doc reference (default: doc).
Tags
Return values
array<string|int, mixed> —An array containing a single AQL condition expression.