add derive + docs
This commit is contained in:
parent
5da65fb603
commit
ca2b0036f0
11 changed files with 400 additions and 43 deletions
|
@ -1,7 +1,7 @@
|
|||
/// This trait allows a `Model` to be validated.
|
||||
pub trait Validate {
|
||||
/// Validate the `Model`
|
||||
async fn validate(&self) -> bool;
|
||||
fn validate(&self) -> impl std::future::Future<Output = bool> + Send;
|
||||
}
|
||||
|
||||
/// Validate a value and return `false` if validation fails.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue