StoreErrorReason
public enum StoreErrorReason
The possible underlying reasons a .storeError
error occurs.
- backendError: An error occurred with the storage backend (LMDB).
- noIDPresentInDocument: The document did not have an
_id
when attempting to decode it. - nonStringKeyInDocument: The document, represented as a CBOR map, had a key that was not a string.
- invalidDocumentStructure: The document’s internal representation was invalid.
- failedToDecodeDocumentData: The document’s data could not be decoded.
- failedToGetDocumentData: The document’s data at the specified path could not be obtained.
- failedToDecodeDocumentID: The document’s ID could not be decoded.
- failedToDecodeDocument: The document could not be decoded.
- queryCompilationFailed: Compilation of the provided query failed.
- unexpectedQueryCompilationReturnCode: An unexpected return code was received when compiling the provided query.
- failedToInitialiseDittoDirectory: The directory that DittoKit attempted to use for its persisted data could not be initialised.
- invalidLiveQueryID: The live query has not obtained a valid ID.
- documentNotFound: The document could not be found.
-
An error occurred with the storage backend (LMDB).
Declaration
Swift
case backendError(lmdbError: LMDBError)
-
The document did not have an
_id
when attempting to decode it.Declaration
Swift
case noIDPresentInDocument
-
The document, represented as a CBOR map, had a key that was not a string.
Declaration
Swift
case nonStringKeyInDocument(key: CBOR)
-
The document’s internal representation was invalid.
Declaration
Swift
case invalidDocumentStructure(cbor: CBOR)
-
The document’s data could not be decoded.
Declaration
Swift
case failedToDecodeDocumentData(error: Error?, data: [UInt8])
-
The document’s data at the specified path could not be obtained.
Declaration
Swift
case failedToGetDocumentData(path: String)
-
The document’s ID could not be decoded.
Declaration
Swift
case failedToDecodeDocumentID(error: Error)
-
The document could not be decoded.
Declaration
Swift
case failedToDecodeDocument(error: Error)
-
Compilation of the provided query failed.
Declaration
Swift
case queryCompilationFailed(query: String)
-
An unexpected return code was received when compiling the provided query.
Declaration
Swift
case unexpectedQueryCompilationReturnCode(returnCode: Ditto_QueryCompileResult, query: String)
-
The directory that DittoKit attempted to use for its persisted data could not be initialised.
Declaration
Swift
case failedToInitialiseDittoDirectory(error: Error)
-
The live query has not obtained a valid ID.
Declaration
Swift
case invalidLiveQueryID(Int64)
-
The document could not be found.
Declaration
Swift
case documentNotFound(id: String)