pub struct ArtifactSpec {
pub name: String,
pub display: String,
pub required: Vec<String>,
pub recommended: Vec<String>,
pub optional: Vec<String>,
pub metadata: Vec<(String, Vec<String>)>,
pub retired_status: Vec<String>,
pub descriptions: Vec<(String, String)>,
pub guidance: Vec<(String, Vec<String>)>,
pub synonyms: Vec<(String, String)>,
pub id_field: Option<String>,
pub starter_bodies: Vec<(String, String)>,
}Expand description
One artifact type’s schema. Field names/order mirror the Python dataclass.
Fields§
§name: StringCanonical key, e.g. "requirement".
display: StringHuman label, e.g. "Requirement".
required: Vec<String>Sections that define the type (scored at 1.0).
recommended: Vec<String>Expected-but-optional sections (scored at 0.5).
optional: Vec<String>Recognized/extracted sections, never scored, never “missing”.
metadata: Vec<(String, Vec<String>)>{section -> allowed values}, in declared order.
retired_status: Vec<String>Subset of metadata["status"] marking retirement.
descriptions: Vec<(String, String)>Schema-render description hints ({section -> text}), declared order.
guidance: Vec<(String, Vec<String>)>Improve/template guidance hints ({section -> [lines]}), declared order.
synonyms: Vec<(String, String)>Alt heading -> canonical section, applied before matching (per-spec).
id_field: Option<String>Canonical-id section; no spec sets it today (always None).
starter_bodies: Vec<(String, String)>Template starter bodies ({section -> text}), declared order.
Implementations§
Trait Implementations§
Source§impl Clone for ArtifactSpec
impl Clone for ArtifactSpec
Source§fn clone(&self) -> ArtifactSpec
fn clone(&self) -> ArtifactSpec
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ArtifactSpec
impl RefUnwindSafe for ArtifactSpec
impl Send for ArtifactSpec
impl Sync for ArtifactSpec
impl Unpin for ArtifactSpec
impl UnsafeUnpin for ArtifactSpec
impl UnwindSafe for ArtifactSpec
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
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>
Converts
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>
Converts
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