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.
Trait Implementations§
Source§impl Error for Error
impl Error for Error
Source§fn description(&self) -> &str
fn description(&self) -> &str
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
impl Copy for Error
impl Eq for Error
impl StructuralPartialEq for Error
Auto Trait Implementations§
impl Freeze for Error
impl RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnwindSafe for Error
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)