120 unsigned columnIndex)
CBLAPI;
#define CBLAPI
Definition: CBL_Compat.h:98
#define _cbl_nullable
Definition: CBL_Compat.h:86
#define CBL_CAPI_BEGIN
Definition: CBL_Compat.h:99
#define CBL_CAPI_END
Definition: CBL_Compat.h:100
#define CBL_ENUM(_type, _name)
Definition: CBL_Compat.h:56
#define _cbl_warn_unused
Definition: CBL_Compat.h:41
struct CBLDatabase CBLDatabase
A connection to an open database.
Definition: CBLBase.h:182
struct CBLListenerToken CBLListenerToken
An opaque 'cookie' representing a registered listener callback.
Definition: CBLBase.h:259
FLDict _cbl_nullable CBLQuery_Parameters(const CBLQuery *query)
Returns the query's current parameter bindings, if any.
_cbl_warn_unused FLArray CBLDatabase_GetIndexNames(CBLDatabase *db)
Returns the names of the indexes on this database, as a Fleece array of strings.
CBLQuery * CBLResultSet_GetQuery(const CBLResultSet *rs)
Returns the Query that created this ResultSet.
FLValue CBLResultSet_ValueForKey(const CBLResultSet *, FLString key)
Returns the value of a column of the current result, given its name.
void(* CBLQueryChangeListener)(void *_cbl_nullable context, CBLQuery *query, CBLListenerToken *token)
A callback to be invoked after the query's results have changed.
Definition: CBLQuery.h:204
void CBLQuery_SetParameters(CBLQuery *query, FLDict parameters)
Assigns values to the query's parameters.
_cbl_warn_unused FLSliceResult CBLQuery_Explain(const CBLQuery *)
Returns information about the query, including the translated SQLite form, and the search strategy.
FLSlice CBLQuery_ColumnName(const CBLQuery *, unsigned columnIndex)
Returns the name of a column in the result.
FLArray CBLResultSet_ResultArray(const CBLResultSet *)
Returns the current result as an array of column values.
CBLQueryLanguage
Query languages.
Definition: CBLQuery.h:43
FLDict CBLResultSet_ResultDict(const CBLResultSet *)
Returns the current result as a dictionary mapping column names to values.
_cbl_warn_unused CBLResultSet *_cbl_nullable CBLQuery_Execute(CBLQuery *, CBLError *_cbl_nullable outError)
Runs the query, returning the results.
_cbl_warn_unused bool CBLResultSet_Next(CBLResultSet *)
Moves the result-set iterator to the next result.
bool CBLDatabase_CreateFullTextIndex(CBLDatabase *db, FLString name, CBLFullTextIndexConfiguration config, CBLError *_cbl_nullable outError)
Creates a full-text index.
struct CBLQuery CBLQuery
A compiled database query.
Definition: CBLBase.h:203
struct CBLResultSet CBLResultSet
An iterator over the rows resulting from running a query.
Definition: CBLBase.h:206
_cbl_warn_unused CBLQuery *_cbl_nullable CBLDatabase_CreateQuery(const CBLDatabase *db, CBLQueryLanguage language, FLString queryString, int *_cbl_nullable outErrorPos, CBLError *_cbl_nullable outError)
Creates a new query by compiling the input string.
_cbl_warn_unused CBLListenerToken * CBLQuery_AddChangeListener(CBLQuery *query, CBLQueryChangeListener listener, void *_cbl_nullable context)
Registers a change listener callback with a query, turning it into a "live query" until the listener ...
_cbl_warn_unused CBLResultSet *_cbl_nullable CBLQuery_CopyCurrentResults(const CBLQuery *query, CBLListenerToken *listener, CBLError *_cbl_nullable outError)
Returns the query's entire current result set, after it's been announced via a call to the listener's...
bool CBLDatabase_DeleteIndex(CBLDatabase *db, FLString name, CBLError *_cbl_nullable outError)
Deletes an index given its name.
unsigned CBLQuery_ColumnCount(const CBLQuery *)
Returns the number of columns in each result.
bool CBLDatabase_CreateValueIndex(CBLDatabase *db, FLString name, CBLValueIndexConfiguration config, CBLError *_cbl_nullable outError)
Creates a value index.
FLValue CBLResultSet_ValueAtIndex(const CBLResultSet *, unsigned index)
Returns the value of a column of the current result, given its (zero-based) numeric index.
@ kCBLN1QLLanguage
N1QL syntax
Definition: CBLQuery.h:45
@ kCBLJSONLanguage
JSON query schema
Definition: CBLQuery.h:44
#define CBL_REFCOUNTED(TYPE, NAME)
Definition: CBLBase.h:170
const struct _FLDict * FLDict
A reference to a dictionary (map) value.
Definition: Fleece.h:51
const struct _FLArray * FLArray
A reference to an array value.
Definition: Fleece.h:50
const struct _FLValue * FLValue
A reference to a value of any type.
Definition: Fleece.h:49
A struct holding information about an error.
Definition: CBLBase.h:104
Full-Text Index Configuration.
Definition: CBLQuery.h:287
FLString expressions
The expressions describing each coloumn of the index.
Definition: CBLQuery.h:293
bool ignoreAccents
Should diacritical marks (accents) be ignored? Defaults to false.
Definition: CBLQuery.h:297
CBLQueryLanguage expressionLanguage
The language used in the expressions.
Definition: CBLQuery.h:289
FLString language
The dominant language.
Definition: CBLQuery.h:310
Value Index Configuration.
Definition: CBLQuery.h:267
FLString expressions
The expressions describing each coloumn of the index.
Definition: CBLQuery.h:273
CBLQueryLanguage expressionLanguage
The language used in the expressions.
Definition: CBLQuery.h:269
A simple reference to a block of memory.
Definition: FLSlice.h:46
A heap-allocated block of memory returned from an API call.
Definition: FLSlice.h:64