pub enum CrypterErrorCodeEnum {
Show 15 variants
CipherAlgorithmError = 13_100,
CipherAlgorithmUnsatisfiedIVLength = 13101,
CipherAlgorithmUnsatisfiedKeyLength = 13102,
StreamGeneratorError = 13_200,
FailedWhenCrypting = 13201,
FailedWhenFinalizingCryption = 13202,
FailedWhenFlushingBuffer = 13203,
StreamCrypterError = 13_300,
CurrentIndexNotAtTheEndOfBufferWhenFlushing = 13301,
StringCrypterError = 13_400,
FailedWhenCheckingCrc32ValueOfDecryptedContent = 13401,
FailedWhenEncodingString = 13402,
FailedWhenDecodingString = 13403,
CannotDoCryptionToEmptyString = 13404,
PasswordCannotBeEmpty = 13405,
}Variants§
CipherAlgorithmError = 13_100
密码算法错误段
CipherAlgorithmUnsatisfiedIVLength = 13101
不满足要求的IV长度
CipherAlgorithmUnsatisfiedKeyLength = 13102
不满足要求的Key长度
StreamGeneratorError = 13_200
流生成器错误段
FailedWhenCrypting = 13201
执行密码操作时失败
FailedWhenFinalizingCryption = 13202
完成密码操作时失败
FailedWhenFlushingBuffer = 13203
刷新缓冲区时失败
StreamCrypterError = 13_300
流加密器错误段
CurrentIndexNotAtTheEndOfBufferWhenFlushing = 13301
刷新时当前下标不在缓冲区的最后
StringCrypterError = 13_400
字符串加密器错误段
FailedWhenCheckingCrc32ValueOfDecryptedContent = 13401
解密后内容无法通过校验
FailedWhenEncodingString = 13402
字符串编码时失败
FailedWhenDecodingString = 13403
字符串解码时失败
CannotDoCryptionToEmptyString = 13404
不能对空串进行密码操作
PasswordCannotBeEmpty = 13405
密码不能为空
Trait Implementations§
Source§impl FromPrimitive for CrypterErrorCodeEnum
impl FromPrimitive for CrypterErrorCodeEnum
Source§fn from_i64(n: i64) -> Option<Self>
fn from_i64(n: i64) -> Option<Self>
Converts an
i64 to return an optional value of this type. If the
value cannot be represented by this type, then None is returned.Source§fn from_u64(n: u64) -> Option<Self>
fn from_u64(n: u64) -> Option<Self>
Converts an
u64 to return an optional value of this type. If the
value cannot be represented by this type, then None is returned.Source§fn from_isize(n: isize) -> Option<Self>
fn from_isize(n: isize) -> Option<Self>
Converts an
isize to return an optional value of this type. If the
value cannot be represented by this type, then None is returned.Source§fn from_i8(n: i8) -> Option<Self>
fn from_i8(n: i8) -> Option<Self>
Converts an
i8 to return an optional value of this type. If the
value cannot be represented by this type, then None is returned.Source§fn from_i16(n: i16) -> Option<Self>
fn from_i16(n: i16) -> Option<Self>
Converts an
i16 to return an optional value of this type. If the
value cannot be represented by this type, then None is returned.Source§fn from_i32(n: i32) -> Option<Self>
fn from_i32(n: i32) -> Option<Self>
Converts an
i32 to return an optional value of this type. If the
value cannot be represented by this type, then None is returned.Source§fn from_i128(n: i128) -> Option<Self>
fn from_i128(n: i128) -> Option<Self>
Converts an
i128 to return an optional value of this type. If the
value cannot be represented by this type, then None is returned. Read moreSource§fn from_usize(n: usize) -> Option<Self>
fn from_usize(n: usize) -> Option<Self>
Converts a
usize to return an optional value of this type. If the
value cannot be represented by this type, then None is returned.Source§fn from_u8(n: u8) -> Option<Self>
fn from_u8(n: u8) -> Option<Self>
Converts an
u8 to return an optional value of this type. If the
value cannot be represented by this type, then None is returned.Source§fn from_u16(n: u16) -> Option<Self>
fn from_u16(n: u16) -> Option<Self>
Converts an
u16 to return an optional value of this type. If the
value cannot be represented by this type, then None is returned.Source§fn from_u32(n: u32) -> Option<Self>
fn from_u32(n: u32) -> Option<Self>
Converts an
u32 to return an optional value of this type. If the
value cannot be represented by this type, then None is returned.Source§fn from_u128(n: u128) -> Option<Self>
fn from_u128(n: u128) -> Option<Self>
Converts an
u128 to return an optional value of this type. If the
value cannot be represented by this type, then None is returned. Read moreAuto Trait Implementations§
impl Freeze for CrypterErrorCodeEnum
impl RefUnwindSafe for CrypterErrorCodeEnum
impl Send for CrypterErrorCodeEnum
impl Sync for CrypterErrorCodeEnum
impl Unpin for CrypterErrorCodeEnum
impl UnwindSafe for CrypterErrorCodeEnum
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