Options
All
  • Public
  • Public/Protected
  • All
Menu

Defines criteria for filtering and ordering a result set of Coaty objects. Used in combination with Query events and database operations, and with the ObjectMatcher functionality.

Hierarchy

Index

Properties

Optional conditions

A single condition or a set of conditions for filtering objects (optional). If not specified or empty, all objects are selected.

A set of filter conditions can be combined by logical AND or OR.

An object filter condition is defined as a tuple specifying the name of an object property and a filter expression. The filter expression must evaluate to true when applied to the property's value for the condition to become true.

The object property to be applied for filtering is specified either in dot notation or array notation. In dot notation, the name of the object property is specified as a string (e.g. "objectId"). It may include dots (.) to access nested properties of subobjects (e.g. "message.name"). If a single property name contains dots itself, you obviously cannot use dot notation. Instead, specify the property or nested properties as an array of strings (e.g. ["property.with.dots", "subproperty.with.dots"]).

A filter expression is a tuple consisting of a filter operator and an operator-specific number of filter operands. You should use one of the typesafe filterOp functions to specify a filter expression.

Optional orderByProperties

orderByProperties?: [ObjectFilterProperties, "Asc" | "Desc"][]

Determines the ordering of result objects by an array of (property name - sort order) tuples. The results are ordered by the first tuple, then by the second tuple, etc.

The object property used for ordering can be specified either in dot notation or array notation. In dot notation, the name of the object property is specified as a string (e.g. "objectId"). It may include dots (.) to access nested properties of subobjects (e.g. "message.name"). If a single property name contains dots itself, you obviously cannot use dot notation. Instead, specify the property or nested properties as an array of strings (e.g. ["property.with.dots", "subproperty.with.dots"]).

Optional skip

skip?: number

If skip count is given that many objects are skipped before beginning to return result objects. Typically, this option is only useful if the orderByProperties option is also specified to ensure consistent ordering of paginated results.

Optional take

take?: number

If a take count is given, no more than that many objects will be returned (but possibly less, if the request itself yields less objects). Typically, this option is only useful if the orderByProperties option is also specified to ensure consistent ordering of paginated results.

Generated using TypeDoc