Files
moli/moli-webcrypto/src/error.rs
T
2026-08-11 00:10:12 +08:00

17 lines
346 B
Rust

#[derive(Clone, Copy, Debug, Eq, PartialEq)]
pub enum WebCryptoError {
Data,
Operation,
Syntax,
}
impl WebCryptoError {
pub fn message(self) -> &'static str {
match self {
Self::Data => "DataError",
Self::Operation => "OperationError",
Self::Syntax => "SyntaxError",
}
}
}