pub struct ProviderError {
pub category: ProviderErrorCategory,
pub code: String,
pub message: String,
pub retryable: Option<bool>,
pub details: Option<Value>,
}Expand description
Normalized provider error payload.
Fields§
§category: ProviderErrorCategory§code: String§message: String§retryable: Option<bool>§details: Option<Value>Implementations§
Source§impl ProviderError
impl ProviderError
pub fn new( category: ProviderErrorCategory, code: impl Into<String>, message: impl Into<String>, ) -> Self
pub fn with_retryable(self, retryable: bool) -> Self
pub fn with_details(self, details: Value) -> Self
pub fn is_retryable(&self) -> bool
Trait Implementations§
Source§impl Clone for ProviderError
impl Clone for ProviderError
Source§fn clone(&self) -> ProviderError
fn clone(&self) -> ProviderError
Returns a duplicate of the value. Read more
1.0.0 · 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 ProviderError
impl Debug for ProviderError
Source§impl<'de> Deserialize<'de> for ProviderError
impl<'de> Deserialize<'de> for ProviderError
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 PartialEq for ProviderError
impl PartialEq for ProviderError
Source§impl Serialize for ProviderError
impl Serialize for ProviderError
impl StructuralPartialEq for ProviderError
Auto Trait Implementations§
impl Freeze for ProviderError
impl RefUnwindSafe for ProviderError
impl Send for ProviderError
impl Sync for ProviderError
impl Unpin for ProviderError
impl UnsafeUnpin for ProviderError
impl UnwindSafe for ProviderError
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