Skip to main content

ConstrainedTypeInput

Struct ConstrainedTypeInput 

Source
pub struct ConstrainedTypeInput { /* private fields */ }
Expand description

Input shim for type:ConstrainedType. Used as Certify::Input for InhabitanceResolver, TowerCompletenessResolver, and IncrementalCompletenessResolver.

Trait Implementations§

Source§

impl Clone for ConstrainedTypeInput

Source§

fn clone(&self) -> ConstrainedTypeInput

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl ConstrainedTypeShape for ConstrainedTypeInput

Source§

const IRI: &'static str = "https://uor.foundation/type/ConstrainedType"

IRI of the ontology type:ConstrainedType instance this shape represents.
Source§

const SITE_COUNT: usize = 0

Number of sites (fields) this constrained type carries.
Source§

const CONSTRAINTS: &'static [ConstraintRef]

Per-site constraint list. Empty means unconstrained.
Source§

const CYCLE_SIZE: u64 = 1

ADR-032: cardinality of the shape’s value-set (the cycle structure of the shape under the substrate’s discrete-clock model). Used by the prism_model! macro to lower first_admit (closure-body grammar G16) to the correct descent measure. Conventions: Read more
Source§

const SITE_BUDGET: usize = Self::SITE_COUNT

Ontology-level siteBudget: count of data sites only, excluding bookkeeping introduced by composition (coproduct tag sites, etc.). Equals SITE_COUNT for leaf shapes and for shapes whose composition introduces no bookkeeping (products, cartesian products). Strictly less than SITE_COUNT for coproduct shapes and any shape whose SITE_COUNT includes inherited bookkeeping. Introduced by the Product/Coproduct Completion Amendment §4a; defaults to SITE_COUNT so pre-amendment shape impls remain valid without edits.
Source§

impl Debug for ConstrainedTypeInput

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
Source§

impl Default for ConstrainedTypeInput

Source§

fn default() -> ConstrainedTypeInput

Returns the “default value” for a type. Read more
Source§

impl FoundationClosed for ConstrainedTypeInput

Source§

fn arena_slice() -> &'static [Term]

Returns the term-tree arena slice the prism_model! macro emitted for this route witness. run_route reads this to populate the CompileUnit’s root_term before invoking run.
Source§

impl Hash for ConstrainedTypeInput

Source§

fn hash<__H>(&self, state: &mut __H)
where __H: Hasher,

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl IntoBindingValue for ConstrainedTypeInput

Source§

const MAX_BYTES: usize = 0

Maximum byte length any value of this shape can produce when serialized via [into_binding_bytes]. Used by run_route to size the on-stack buffer and reject inputs that would overflow.
Source§

fn into_binding_bytes(&self, _out: &mut [u8]) -> Result<usize, ShapeViolation>

Serialize this input value into the binding-table form. out is a fixed-capacity buffer the call-site provides; the implementation writes the canonical content-addressable byte sequence and returns the written length. Read more
Source§

impl PartialEq for ConstrainedTypeInput

Source§

fn eq(&self, other: &ConstrainedTypeInput) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl PartitionProductFields for ConstrainedTypeInput

Source§

const FIELDS: &'static [(u32, u32)]

Per-factor (byte_offset, byte_length) pairs in declaration order. Length is the same as FIELD_NAMES.len().
Source§

const FIELD_NAMES: &'static [&'static str]

Per-factor names. Empty string "" for positional-only partition_product!(Name, A, B) emissions; non-empty for named-field partition_product!(Name, lhs: A, rhs: B) form. Length matches FIELDS.len().
Source§

fn field_index_by_name(name: &str) -> usize

Linear search returning the field index whose FIELD_NAMES entry equals name, or usize::MAX if not found. Delegates to the free const fn field_index_by_name_in so the result is usable inside const-eval contexts on stable Rust 1.83 (where const trait methods are unavailable).
Source§

impl Copy for ConstrainedTypeInput

Source§

impl Eq for ConstrainedTypeInput

Source§

impl GroundedShape for ConstrainedTypeInput

Source§

impl OntologyTarget for ConstrainedTypeInput

Source§

impl StructuralPartialEq for ConstrainedTypeInput

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.