Skip to main content

FieldRuleExt

Trait FieldRuleExt 

Source
pub trait FieldRuleExt {
    // Required methods
    fn enum_constraint(&self) -> Option<(&[Term], bool)>;
    fn reference(&self) -> Option<&str>;
}
Expand description

Convenience accessors for a flower FieldRule, mirroring what used to be inherent methods before fig_schema::FieldRule became generic. A local trait, since inherent impls can’t be added to a foreign generic type.

Required Methods§

Source

fn enum_constraint(&self) -> Option<(&[Term], bool)>

The controlled vocabulary this rule enforces, if any.

Source

fn reference(&self) -> Option<&str>

The reference/relation this rule describes, if any.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§