pub enum Error {
Show 15 variants
TryFromSlice(String),
ChaCha20Poly1305(Error),
InvalidScryptParams(InvalidParams),
InvalidScryptOutputLen(InvalidOutputLen),
Keys(Error),
InvalidLength {
expected: usize,
found: usize,
},
UnsupportedVersion(u8),
UnknownVersion(u8),
UnknownKeySecurity(u8),
VersionNotFound,
Log2RoundNotFound,
SaltNotFound,
NonceNotFound,
KeySecurityNotFound,
CipherTextNotFound,
}Expand description
NIP49 error
Variants§
TryFromSlice(String)
Try from slice
ChaCha20Poly1305(Error)
ChaCha20Poly1305 error
InvalidScryptParams(InvalidParams)
Invalid scrypt params
InvalidScryptOutputLen(InvalidOutputLen)
Invalid scrypt output len
Keys(Error)
Keys error
InvalidLength
Invalid len
UnsupportedVersion(u8)
Unsupported version
UnknownVersion(u8)
Unknown version
UnknownKeySecurity(u8)
Unknown Key Security
VersionNotFound
Version not found
Log2RoundNotFound
Log2 round not found
SaltNotFound
Salt not found
NonceNotFound
Nonce not found
KeySecurityNotFound
Key security not found
CipherTextNotFound
Cipthertext not found
Trait Implementations§
source§impl Error for Error
impl Error for Error
1.30.0 · source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
The lower-level source of this error, if any. Read more
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
source§impl From<InvalidOutputLen> for Error
impl From<InvalidOutputLen> for Error
source§fn from(e: InvalidOutputLen) -> Error
fn from(e: InvalidOutputLen) -> Error
Converts to this type from the input type.
source§impl From<InvalidParams> for Error
impl From<InvalidParams> for Error
source§fn from(e: InvalidParams) -> Error
fn from(e: InvalidParams) -> Error
Converts to this type from the input type.
source§impl From<TryFromSliceError> for Error
impl From<TryFromSliceError> for Error
source§fn from(e: TryFromSliceError) -> Error
fn from(e: TryFromSliceError) -> Error
Converts to this type from the input type.
source§impl PartialEq for Error
impl PartialEq 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
Mutably borrows from an owned value. Read more
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.