pub struct EthosError {
pub code: ErrorCode,
pub message: String,
}Expand description
The Ethos error type: stable code + deterministic message. Messages follow fixed templates (determinism contract §8) — no paths, no timestamps.
Fields§
§code: ErrorCodeStable code.
message: StringDeterministic, template-derived message.
Implementations§
Trait Implementations§
Source§impl Clone for EthosError
impl Clone for EthosError
Source§fn clone(&self) -> EthosError
fn clone(&self) -> EthosError
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for EthosError
impl Debug for EthosError
Source§impl<'de> Deserialize<'de> for EthosError
impl<'de> Deserialize<'de> for EthosError
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for EthosError
impl Display for EthosError
impl Eq for EthosError
Source§impl Error for EthosError
impl Error for EthosError
1.30.0 · 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 PartialEq for EthosError
impl PartialEq for EthosError
Source§fn eq(&self, other: &EthosError) -> bool
fn eq(&self, other: &EthosError) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for EthosError
impl Serialize for EthosError
impl StructuralPartialEq for EthosError
Auto Trait Implementations§
impl Freeze for EthosError
impl RefUnwindSafe for EthosError
impl Send for EthosError
impl Sync for EthosError
impl Unpin for EthosError
impl UnsafeUnpin for EthosError
impl UnwindSafe for EthosError
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