LiteCore
Couchbase Lite cross-platform core implementation
Loading...
Searching...
No Matches
c4DocEnumerator.h
Go to the documentation of this file.
1//
2// c4DocEnumerator.h
3//
4// Copyright 2015-Present Couchbase, Inc.
5//
6// Use of this software is governed by the Business Source License included
7// in the file licenses/BSL-Couchbase.txt. As of the Change Date specified
8// in that file, in accordance with the Business Source License, use of this
9// software will be governed by the Apache License, Version 2.0, included in
10// the file licenses/APL2.txt.
11//
12
13#pragma once
14
16
19
22
23
28
38 const C4EnumeratorOptions* C4NULLABLE options,
39 C4Error* C4NULLABLE outError) C4API;
40
51 const C4EnumeratorOptions* C4NULLABLE options,
52 C4Error* C4NULLABLE outError) C4API;
53
59
67
76
78
#define NODISCARD
Definition CompilerSupport.h:63
#define CBL_CORE_API
Definition c4Compat.h:131
#define C4NULLABLE
Definition c4Compat.h:38
#define C4API
Definition c4Compat.h:106
#define C4_ASSUME_NONNULL_BEGIN
Definition c4Compat.h:36
#define C4API_END_DECLS
Definition c4Compat.h:108
#define C4API_BEGIN_DECLS
Definition c4Compat.h:107
#define C4_ASSUME_NONNULL_END
Definition c4Compat.h:37
struct C4DocEnumerator C4DocEnumerator
Opaque handle to a document enumerator.
Definition c4Base.h:144
uint64_t C4SequenceNumber
A database sequence number, representing the order in which a revision was created.
Definition c4Base.h:90
struct C4Collection C4Collection
Opaque handle to a namespace of documents in an opened database.
Definition c4Base.h:125
NODISCARD CBL_CORE_API C4DocEnumerator * c4coll_enumerateAllDocs(C4Collection *collection, const C4EnumeratorOptions *options, C4Error *outError)
Creates an enumerator ordered by docID.
NODISCARD CBL_CORE_API bool c4enum_next(C4DocEnumerator *e, C4Error *outError)
Advances the enumerator to the next document.
NODISCARD CBL_CORE_API C4DocEnumerator * c4coll_enumerateChanges(C4Collection *collection, C4SequenceNumber since, const C4EnumeratorOptions *options, C4Error *outError)
Creates an enumerator ordered by sequence.
NODISCARD CBL_CORE_API C4Document * c4enum_getDocument(C4DocEnumerator *e, C4Error *outError)
Returns the current document, if any, from an enumerator.
void c4enum_close(C4DocEnumerator *e)
Closes an enumeration.
CBL_CORE_API bool c4enum_getDocumentInfo(C4DocEnumerator *e, C4DocumentInfo *outInfo)
Stores the metadata of the enumerator's current document into the supplied C4DocumentInfo struct.
Describes a version-controlled document.
Definition c4DocumentStruct.h:32
Metadata about a document (actually about its current revision.)
Definition c4DocEnumeratorTypes.h:52
Options for enumerating over all documents.
Definition c4DocEnumeratorTypes.h:42
An error value.
Definition c4Error.h:133