pub struct MustReach {
pub relationships: Vec<String>,
pub direction: ReachDirection,
pub terminal_types: Vec<String>,
pub max_depth: Option<u32>,
pub severity: ConstraintSeverity,
}Expand description
One reachability obligation on a type definition. The obligated
entity must reach at least one non-stub entity whose type is in
terminal_types, walking edges whose rel-type is in
relationships (an inline relation set), in direction, within
max_depth hops when bounded. Evaluated on the health sweep only
(constraints axis), never on the write path — no single write
completes a transitive absence. The incoming direction with
max_depth: 1 covers the required-incoming-edge case.
Fields§
§relationships: Vec<String>Edge names the walk follows — any name in the set continues the path. Loader validates each against the schema’s relationship vocabulary.
direction: ReachDirectionout follows edges pointing away from the walked entity, in
follows edges pointing at it — the same vocabulary the store
and memstead_search speak.
terminal_types: Vec<String>Type names that satisfy the obligation when reached. Loader validates each against the schema’s declared types.
max_depth: Option<u32>Maximum number of hops a conforming path may take. Absent = unbounded. Zero refuses at load (nothing is reachable in zero hops).
severity: ConstraintSeverityAlways warn — the loader refuses block on this form.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for MustReach
impl<'de> Deserialize<'de> for MustReach
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl JsonSchema for MustReach
impl JsonSchema for MustReach
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read more