pub struct Frontmatter {
pub meta: NodeMeta,
pub kind: FrontmatterKind,
pub value: String,
}Expand description
A leading frontmatter block. Source: --- YAML or +++ TOML at the top of
the document.
Fields§
§meta: NodeMetaNode metadata (source span).
kind: FrontmatterKindWhether the frontmatter is YAML or TOML.
value: StringThe literal frontmatter contents (between the fences).
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
impl Eq for Frontmatter
Source§impl From<Frontmatter> for Block
impl From<Frontmatter> for Block
Source§fn from(node: Frontmatter) -> Self
fn from(node: Frontmatter) -> Self
Converts to this type from the input type.
Source§impl PartialEq for Frontmatter
impl PartialEq for Frontmatter
Source§fn eq(&self, other: &Frontmatter) -> bool
fn eq(&self, other: &Frontmatter) -> bool
Tests for
self and other values to be equal, and is used by ==.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