pub enum Error {
Show 21 variants
KeyExist,
NotFound,
PageNotFound,
Corrupted,
Panic,
VersionMismatch,
Invalid,
MapFull,
DbsFull,
ReadersFull,
TlsFull,
TxnFull,
CursorFull,
PageFull,
MapResized,
Incompatible,
BadRslot,
BadTxn,
BadValSize,
BadDbi,
Other(c_int),
}
Expand description
An LMDB error kind.
Variants§
KeyExist
key/data pair already exists.
NotFound
key/data pair not found (EOF).
PageNotFound
Requested page not found - this usually indicates corruption.
Corrupted
Located page was wrong type.
Panic
Update of meta page failed or environment had fatal error.
VersionMismatch
Environment version mismatch.
Invalid
File is not a valid LMDB file.
MapFull
Environment mapsize reached.
DbsFull
Environment maxdbs reached.
ReadersFull
Environment maxreaders reached.
TlsFull
Too many TLS keys in use - Windows only.
TxnFull
Txn has too many dirty pages.
CursorFull
Cursor stack too deep - internal error.
PageFull
Page has not enough space - internal error.
MapResized
Database contents grew beyond environment mapsize.
Incompatible
MDB_Incompatible: Operation and DB incompatible, or DB flags changed.
BadRslot
Invalid reuse of reader locktable slot.
BadTxn
Transaction cannot recover - it must be aborted.
BadValSize
Unsupported size of key/DB name/data, or wrong DUP_FIXED size.
BadDbi
The specified DBI was changed unexpectedly.
Other(c_int)
Other error.
Implementations§
Source§impl Error
impl Error
Sourcepub fn from_err_code(err_code: c_int) -> Error
pub fn from_err_code(err_code: c_int) -> Error
Converts a raw error code to an Error
.
Sourcepub fn to_err_code(&self) -> c_int
pub fn to_err_code(&self) -> c_int
Converts an Error
to the raw error code.