pub struct SchemaRulesConfig {
pub unknown_label: RuleConfig,
pub missing_param: RuleConfig,
pub param_type_mismatch: RuleConfig,
pub bad_attachment: RuleConfig,
pub body_shape_mismatch: RuleConfig,
}Expand description
Schema-validation diagnostics. Each field maps to one of the
schema pre-validation checks the analyser performs before
dispatching to an extension handler. See the Extending Lex
proposal (comms/specs/proposals/extending-lex.lex) §13.2.
Fields§
§unknown_label: RuleConfigA label is invoked whose namespace is registered, but no schema entry exists for the label itself. Typically a typo or an out-of-version label. Intrinsic default: deny.
missing_param: RuleConfigA label invocation omits a parameter the schema marks as required. Intrinsic default: deny.
param_type_mismatch: RuleConfigA label parameter’s value does not match the type the schema declares. Intrinsic default: deny.
bad_attachment: RuleConfigA label attaches to a container shape the schema disallows (e.g. attaching a paragraph-only label to a session). Intrinsic default: deny.
body_shape_mismatch: RuleConfigA label body’s shape (none / text / lex) does not match
the schema’s declared body kind. Intrinsic default: deny.
Trait Implementations§
Source§impl Clone for SchemaRulesConfig
impl Clone for SchemaRulesConfig
Source§fn clone(&self) -> SchemaRulesConfig
fn clone(&self) -> SchemaRulesConfig
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 SchemaRulesConfig
impl Debug for SchemaRulesConfig
Source§impl Default for SchemaRulesConfig
impl Default for SchemaRulesConfig
Source§fn default() -> SchemaRulesConfig
fn default() -> SchemaRulesConfig
Source§impl<'de> Deserialize<'de> for SchemaRulesConfig
impl<'de> Deserialize<'de> for SchemaRulesConfig
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 Schema for SchemaRulesConfig
impl Schema for SchemaRulesConfig
Source§const STATIC: &'static SchemaStatic
const STATIC: &'static SchemaStatic
static SchemaStatic = ... initializers.Source§fn schema() -> &'static Schema
fn schema() -> &'static Schema
OnceLock; the helper cached_runtime_schema keeps the
generated body small.Source§fn schema_arc() -> Arc<Schema>
fn schema_arc() -> Arc<Schema>
Arc-flavored access to the same cached runtime view. Used by the
macro-driven builder (crate::SchemaConfigBuilder) to avoid
cloning the schema tree per builder construction — the runtime
spec stores an Arc<Schema> and the cache hands out cheap
reference-counted handles to it. Cost: one Arc::clone per call
(atomic increment, no allocation).Source§fn schema_static() -> &'static SchemaStatic
fn schema_static() -> &'static SchemaStatic
Self::STATIC.Source§fn field_paths() -> Vec<String>
fn field_paths() -> Vec<String>
--list-keys flags) replace hand-maintained “known paths”
constants — the macro recomputes the list every time a field is
added or removed. Read moreAuto Trait Implementations§
impl Freeze for SchemaRulesConfig
impl RefUnwindSafe for SchemaRulesConfig
impl Send for SchemaRulesConfig
impl Sync for SchemaRulesConfig
impl Unpin for SchemaRulesConfig
impl UnsafeUnpin for SchemaRulesConfig
impl UnwindSafe for SchemaRulesConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more