Trait valico::common::error::ValicoError
source · pub trait ValicoError: Error + Send + Debug + GetTypeId {
// Required methods
fn get_code(&self) -> &str;
fn get_path(&self) -> &str;
fn get_title(&self) -> &str;
// Provided method
fn get_detail(&self) -> Option<&str> { ... }
}
Required Methods§
Provided Methods§
fn get_detail(&self) -> Option<&str>
Implementations§
source§impl dyn ValicoError
impl dyn ValicoError
sourcepub fn is<E: ValicoError>(&self) -> bool
pub fn is<E: ValicoError>(&self) -> bool
Is this Error
object of type E
?
sourcepub fn downcast<E: ValicoError>(&self) -> Option<&E>
pub fn downcast<E: ValicoError>(&self) -> Option<&E>
If this error is E
, downcast this error to E
, by reference.