Skip to main content

DomainConstraint

Trait DomainConstraint 

Source
pub trait DomainConstraint:
    Debug
    + Send
    + Sync
    + 'static {
    type Value;

    // Required method
    fn check(&self, var: &dyn Var, v: &Self::Value) -> Result<(), VarError>;
}

Required Associated Types§

Required Methods§

Source

fn check(&self, var: &dyn Var, v: &Self::Value) -> Result<(), VarError>

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§

Source§

impl DomainConstraint for NonZeroDuration

Source§

impl DomainConstraint for NumericNonNegNonNan

Source§

type Value = Decimal<mz_repr::::adt::numeric::Numeric::{constant#0}>

Source§

impl<R> DomainConstraint for ByteSizeInRange<R>
where R: RangeBounds<ByteSize> + Debug + Send + Sync + 'static,

Source§

impl<R> DomainConstraint for NumericInRange<R>
where R: RangeBounds<f64> + Debug + Send + Sync + 'static,

Source§

type Value = Decimal<mz_repr::::adt::numeric::Numeric::{constant#0}>