Skip to main content

Validate

Trait Validate 

Source
pub trait Validate<T>
where T: Debug + Any,
{ // Required method fn validate(&self) -> Result<(), Errors<T>>; }
Expand description

A validatable type.

Required Methods§

Source

fn validate(&self) -> Result<(), Errors<T>>

Validates the value.

If invalid, returns details about why the value failed validation.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§