pub enum CapsulaError {
Io(Error),
Serialization(Error),
Configuration {
message: String,
},
HookFailed {
hook: String,
message: String,
source: Box<dyn Error + Send + Sync>,
},
Other(String),
}Expand description
Core error type for the Capsula library
This enum defines common infrastructure errors. Hook-specific errors should be defined in their respective crates and converted to CoreError via the HookFailed variant.
Variants§
Io(Error)
I/O operation failed
Serialization(Error)
Serialization/deserialization failed
Configuration
Configuration-related error
HookFailed
Hook execution failed This variant wraps hook-specific errors while preserving the error chain
Other(String)
Generic error for unexpected conditions
Trait Implementations§
Source§impl Debug for CapsulaError
impl Debug for CapsulaError
Source§impl Display for CapsulaError
impl Display for CapsulaError
Source§impl Error for CapsulaError
impl Error for CapsulaError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns 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<Error> for CapsulaError
impl From<Error> for CapsulaError
Auto Trait Implementations§
impl Freeze for CapsulaError
impl !RefUnwindSafe for CapsulaError
impl Send for CapsulaError
impl Sync for CapsulaError
impl Unpin for CapsulaError
impl !UnwindSafe for CapsulaError
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