pub trait DomainRegistry {
// Provided methods
fn rules(
&self,
_schema: u16,
_revision: u16,
) -> Option<&'static [FieldRule]> { ... }
fn validate_block(
&self,
_block: Block<'_>,
_context: &Context<'_, '_>,
) -> Result<(), Error> { ... }
fn descriptor_target_schema(&self, _key: u16) -> Option<u16> { ... }
fn validate_units(
&self,
_units: &str,
_context: &Context<'_, '_>,
) -> Result<(), Error> { ... }
fn validate_grid_frame(
&self,
_frame: Block<'_>,
_context: &Context<'_, '_>,
) -> Result<(), Error> { ... }
fn validate_spatial_entry(
&self,
_entry: Entry<'_>,
frame: Block<'_>,
_context: &Context<'_, '_>,
) -> Result<(), Error> { ... }
fn validate_frame_profile(
&self,
_frame: Block<'_>,
_context: &Context<'_, '_>,
) -> Result<(), Error> { ... }
}Expand description
Domain registries own exact domain field rules and numeric/reference semantics. Returning rules commits the registry to validating that schema, not preserving it. Callbacks must charge variable work through Context::charge_work before doing it.
Provided Methods§
fn rules(&self, _schema: u16, _revision: u16) -> Option<&'static [FieldRule]>
fn validate_block( &self, _block: Block<'_>, _context: &Context<'_, '_>, ) -> Result<(), Error>
Sourcefn descriptor_target_schema(&self, _key: u16) -> Option<u16>
fn descriptor_target_schema(&self, _key: u16) -> Option<u16>
Descriptor keys4/5/6 name family medium/transform/calibration schemas.
fn validate_units( &self, _units: &str, _context: &Context<'_, '_>, ) -> Result<(), Error>
Sourcefn validate_grid_frame(
&self,
_frame: Block<'_>,
_context: &Context<'_, '_>,
) -> Result<(), Error>
fn validate_grid_frame( &self, _frame: Block<'_>, _context: &Context<'_, '_>, ) -> Result<(), Error>
A family-specific grid order may omit shared key7 only after explicit admission. Positive spacing and nonzero dimensions have already been checked.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".