API Reference
FrontMatterBlock
YAML front matter block rendered at the beginning of the document.
Inheritance
- MarkdownBlock
- FrontMatterBlock
Usage
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by
- Method FrontMatterBlock.FromObject
- Method FrontMatterBlock.FromObject``1
- Property MarkdownDoc.DocumentHeader
- Property MarkdownNativeFrontMatterBlock.FrontMatter
Constructors
public FrontMatterBlock() #Methods
public Entry FindEntry(String key, StringComparison comparison = OrdinalIgnoreCase) #EntryFinds a front matter entry by key.
Parameters
- key System.String
- comparison System.StringComparison = OrdinalIgnoreCase
public static FrontMatterBlock FromObject(Object data) #FrontMatterBlockCreates front matter from an anonymous object or dictionary.
Parameters
- data System.Object
public static FrontMatterBlock FromObject<T>(T data) #FrontMatterBlockCreates front matter from a typed object using public readable properties.
Type Parameters
- T
Parameters
- data ``0
public Boolean HasEntry(String key, StringComparison comparison = OrdinalIgnoreCase) #BooleanChecks whether the front matter contains an entry with the specified key.
Parameters
- key System.String
- comparison System.StringComparison = OrdinalIgnoreCase
public Boolean TryGetValue<T>(String key, out T value) #BooleanGets a typed front matter value by key when available.
Type Parameters
- T
Parameters
- key System.String
- value ``0@
Inherited Methods
public Void Accept(MarkdownVisitor visitor) #VoidParameters
- visitor MarkdownVisitor
public IEnumerable<MarkdownObject> Ancestors() #IEnumerable<MarkdownObject>public IEnumerable<MarkdownObject> AncestorsAndSelf() #IEnumerable<MarkdownObject>public IEnumerable<TObject> DescendantObjectsOfType<TObject>() #IEnumerable<TObject>Type Parameters
- TObject
public IEnumerable<MarkdownObject> Descendants() #IEnumerable<MarkdownObject>public override Boolean Equals(Object obj) #BooleanParameters
- obj Object
Properties
public IReadOnlyList<Entry> Entries { get; } #Structured front matter entries in insertion order.
public String RawYaml { get; set; } #Raw YAML payload between the opening and closing front matter fences when parsed from markdown.
public Nullable<MarkdownSourceSpan> BodySourceSpan { get; set; } #Source span for the raw YAML payload between the opening and closing front matter fences.
Inherited Properties
public MarkdownObject Parent { get; } #public MarkdownDoc Document { get; } #public MarkdownObject Root { get; } #public Nullable<Int32> IndexInParent { get; } #public MarkdownObject PreviousSibling { get; } #public MarkdownObject NextSibling { get; } #public Nullable<MarkdownSourceSpan> SourceSpan { get; set; } #public MarkdownAttributeSet Attributes { get; } #public IReadOnlyList<MarkdownObject> ChildObjects { get; } #