pub struct Frontmatter {
pub type_: String,
pub title: Option<String>,
pub description: Option<String>,
pub resource: Option<String>,
pub tags: Vec<String>,
pub status: Option<String>,
pub origin: Option<Origin>,
pub sources: Vec<String>,
}Expand description
A concept document’s frontmatter.
Only Self::type_ is required by the specification; every other field is
omitted entirely when absent rather than written empty, because §11 tells
consumers not to reject a document for a missing optional field and an empty
string is a different claim from silence.
Fields§
§type_: Stringtype — the one required key. Named with a trailing underscore because
type is a Rust keyword; it is written as type.
title: Option<String>title — human-readable display name.
description: Option<String>description — a single-sentence summary.
resource: Option<String>resource — canonical URI for the underlying asset.
tags — categorisation strings.
status: Option<String>status — draft | stable | deprecated.
origin: Option<Origin>The origin, split into generated and verified on render.
sources: Vec<String>sources — where the concept derives from, each with a resource.
Implementations§
Trait Implementations§
Source§impl Clone for Frontmatter
impl Clone for Frontmatter
Source§fn clone(&self) -> Frontmatter
fn clone(&self) -> Frontmatter
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 moreSource§impl Debug for Frontmatter
impl Debug for Frontmatter
Source§impl Default for Frontmatter
impl Default for Frontmatter
Source§fn default() -> Frontmatter
fn default() -> Frontmatter
Returns the “default value” for a type. Read more
impl Eq for Frontmatter
Source§impl PartialEq for Frontmatter
impl PartialEq for Frontmatter
impl StructuralPartialEq for Frontmatter
Auto Trait Implementations§
impl Freeze for Frontmatter
impl RefUnwindSafe for Frontmatter
impl Send for Frontmatter
impl Sync for Frontmatter
impl Unpin for Frontmatter
impl UnsafeUnpin for Frontmatter
impl UnwindSafe for Frontmatter
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.