Constructor
new QueryRequest(targetTypenon-null, clientnon-null, actorRequestFactorynon-null)
Parameters:
Name | Type | Description |
---|---|---|
targetType |
Class.<Message> | the target type of entities |
client |
Client | the client which initiated the request |
actorRequestFactory |
ActorRequestFactory | the request factory |
- Source:
Classes
Methods
_newBuilderFn()
- Source:
_self()
- Source:
limit(count) → {this}
Sets the maximum number of returned entities.
Can only be used in conjunction with the #orderBy condition.
Parameters:
Name | Type | Description |
---|---|---|
count |
number | the max number of response entities |
- Source:
Returns:
self for method chaining
- Type
- this
orderBy(columnnon-null, directionnon-null) → {this}
Sets the sorting order for the retrieved results.
Parameters:
Name | Type | Description |
---|---|---|
column |
String | the column to order by |
direction |
OrderBy.Direction | the ascending/descending direction |
- Source:
Returns:
self for method chaining
- Type
- this
query() → {spine.client.Query}
Builds a `Query` instance based on currently specified filters.
- Source:
Returns:
a `Query` instance
- Type
- spine.client.Query
run() → {Promise.<Array.<Message>>}
Runs the query and obtains the results.
- Source:
Returns:
the asynchronously resolved query results
- Type
- Promise.<Array.<Message>>