|
LiteCore
Couchbase Lite cross-platform core implementation
|
#include "c4QueryTypes.h"Go to the source code of this file.
Functions | |
| NODISCARD CBL_CORE_API C4Query * | c4query_new2 (C4Database *database, C4QueryLanguage language, C4String expression, int *outErrorPos, C4Error *error) |
| Compiles a query from an expression given as JSON. | |
| CBL_CORE_API C4StringResult | c4query_explain (C4Query *) |
| Returns a string describing the implementation of the compiled query. | |
| CBL_CORE_API unsigned | c4query_columnCount (C4Query *) |
| Returns the number of columns (the values specified in the WHAT clause) in each row. | |
| CBL_CORE_API FLString | c4query_columnTitle (C4Query *, unsigned column) |
| Returns a suggested title for a column, which may be: An alias specified in an 'AS' modifier in the column definition A property name A function/operator that computes the column value, e.g. | |
| CBL_CORE_API void | c4query_setParameters (C4Query *query, C4String encodedParameters) |
| Sets the parameter values to use when running the query, if no parameters are given to c4query_run. | |
| NODISCARD CBL_CORE_API C4QueryEnumerator * | c4query_run (C4Query *query, C4String encodedParameters, C4Error *outError) |
| Runs a compiled query. | |
| CBL_CORE_API C4StringResult | c4query_fullTextMatched (C4Query *query, const C4FullTextMatch *term, C4Error *outError) |
| Given a C4FullTextMatch from the enumerator, returns the entire text of the property that was matched. | |
| NODISCARD CBL_CORE_API bool | c4queryenum_next (C4QueryEnumerator *e, C4Error *outError) |
| Advances a query enumerator to the next row, populating its fields. | |
| NODISCARD CBL_CORE_API int64_t | c4queryenum_getRowCount (C4QueryEnumerator *e, C4Error *outError) |
| Returns the total number of rows in the query, if known. | |
| NODISCARD CBL_CORE_API bool | c4queryenum_seek (C4QueryEnumerator *e, int64_t rowIndex, C4Error *outError) |
| Jumps to a specific row. | |
| static NODISCARD bool | c4queryenum_restart (C4QueryEnumerator *e, C4Error *outError) |
| Restarts the enumeration, as though it had just been created: the next call to c4queryenum_next will read the first row, and so on from there. | |
| NODISCARD CBL_CORE_API C4QueryEnumerator * | c4queryenum_refresh (C4QueryEnumerator *e, C4Error *outError) |
| Checks whether the query results have changed since this enumerator was created; if so, returns a new enumerator. | |
| CBL_CORE_API void | c4queryenum_close (C4QueryEnumerator *) |
| Closes an enumerator without freeing it. | |