Skip to main content

StandardError

Trait StandardError 

Source
pub trait StandardError {
    // Required methods
    fn standardize(self) -> TrustformersError;
    fn standardize_with_operation(self, operation: &str) -> TrustformersError;
    fn standardize_with_component(self, component: &str) -> TrustformersError;
    fn standardize_with_context(
        self,
        operation: &str,
        component: &str,
    ) -> TrustformersError;
}
Expand description

Standard error interface that all modules should use

Required Methods§

Source

fn standardize(self) -> TrustformersError

Convert any error to a standardized TrustformersError

Source

fn standardize_with_operation(self, operation: &str) -> TrustformersError

Convert with operation context

Source

fn standardize_with_component(self, component: &str) -> TrustformersError

Convert with component context

Source

fn standardize_with_context( self, operation: &str, component: &str, ) -> TrustformersError

Convert with full context

Implementations on Foreign Types§

Source§

impl StandardError for &str

Source§

impl StandardError for String

Source§

impl StandardError for Error

Implementors§