pub trait InitializerValidator {
// Required method
fn validate_default_value(
&self,
value: &InitializerDefault,
) -> BindResult<ValidatedDefaultValue>;
// Provided method
fn bad_initializer_value(
field_type: String,
value: &InitializerDefault,
) -> BindResult<ValidatedDefaultValue> { ... }
}
Required Methods§
Sourcefn validate_default_value(
&self,
value: &InitializerDefault,
) -> BindResult<ValidatedDefaultValue>
fn validate_default_value( &self, value: &InitializerDefault, ) -> BindResult<ValidatedDefaultValue>
Check that the value is valid for the type
Provided Methods§
fn bad_initializer_value( field_type: String, value: &InitializerDefault, ) -> BindResult<ValidatedDefaultValue>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.