pub struct RequiredOutgoing {
pub relationships: Vec<String>,
pub cardinality: RequiredCardinality,
pub severity: ConstraintSeverity,
}Expand description
One outgoing-edge requirement block on a type definition. Lists one
or more relationship names and a cardinality constraint they must
jointly satisfy. The schema author groups multiple alternative
relationships into a single block when “any of these” satisfies the
rule (e.g. [CHOSEN, REJECTED] together with at_least_one would
require at least one outgoing edge across both names — but the
planning schema lists each as its own block instead, so each block
gets its own warning entry).
Fields§
§relationships: Vec<String>Edge names the rule applies to. Loader validates each against
the schema’s declared relationship vocabulary; unknown names
raise SchemaLoadError::UndeclaredRelationship.
cardinality: RequiredCardinality§severity: ConstraintSeverityConstraint severity (form 4 of the constraint vocabulary):
warn (the historical default — health finding +
MISSING_REQUIRED_OUTGOING write-time warning) or block
(write-time refusal when a create/update would land, or a
relate-remove would leave, the entity below cardinality).
Implementations§
Trait Implementations§
Source§impl Clone for RequiredOutgoing
impl Clone for RequiredOutgoing
Source§fn clone(&self) -> RequiredOutgoing
fn clone(&self) -> RequiredOutgoing
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for RequiredOutgoing
impl Debug for RequiredOutgoing
Source§impl<'de> Deserialize<'de> for RequiredOutgoing
impl<'de> Deserialize<'de> for RequiredOutgoing
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 RequiredOutgoing
impl JsonSchema for RequiredOutgoing
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