QueryResultModel
The QueryResultModel represents the result of a database query.
implements: hash, sequence<AssetModel>, collection<AssetModel>, scalar
bundle: online channel standard (oc)
since 4.2.0
The QueryResultModel represents the result of a database query.
The QueryResult implements both the properties of a collection and a sequence of Assets.
Access via an index will load the complete result into main memory. Hash accesses whose key does not belong to those of the QueryResult, are forwarded to the first asset in the result collection. If the result collection is empty then the result is undefined. The same applies when addressing it as a scalar.
General Features
resultCount ↦ Number
since 4.2.0
Returns the Number of elements in the search result.
Search Result Window
limit(Integer:start, Integer:length) ↦ QueryResultModel
since 4.2.0
Returns a new query result which consists of the elements of the current query result from index 'start' to index 'start' + 'length'.
resultOffset ↦ Number
since 4.2.0
Returns the start index of the result window of this instance in relation to the original search result.
totalResultCount ↦ Number
since 4.2.0
Returns the Number of elements in the original search result collection.
[used as scalar] ↦ String
since 4.2.0
Returns string value of first result AssetModel
Defined hash keys
Delegates other keys to: AssetModel
Methods
relevance(Asset:resultAsset) ↦ Float
since 2018.3.0
Return the relevance value for provided asset calculated by this query