This documentation is also published as Markdown for efficient machine reading: the whole site is indexed at /llms.txt, and every page has a clean Markdown copy at the same URL with .md appended. These are generated from the same source and cost far fewer tokens to read than this rendered HTML.

Skip to main content Skip to navigation

MarkdownFormat Pennington.Pipeline

Dispatch-key conventions for the built-in markdown sources. Each source registered via AddMarkdownContent gets a distinct key (SourceKey) so the pipeline routes it to that source's front-matter parser instead of a single shared one — they all still render through the one markdown renderer. Matches recognises any markdown key, for consumers that ask "is this a markdown file?" rather than which source produced it.

Fields

Key string
Default: "markdown"
Key for the first markdown source, and the standalone key for single-source hosts.

Methods

Matches

#
public static bool Matches(string format)

True when format is one of the markdown dispatch keys produced by SourceKey.

Parameters

format string

Returns

bool

SourceKey

#
public static string SourceKey(int index)

Distinct dispatch key for the markdown source at index in registration order (index 0 keeps the bare Key).

Parameters

index int

Returns

string

Pennington.Pipeline.MarkdownFormat

namespace Pennington.Pipeline;

/// Dispatch-key conventions for the built-in markdown sources. Each source registered via AddMarkdownContent gets a distinct key (SourceKey) so the pipeline routes it to that source's front-matter parser instead of a single shared one — they all still render through the one markdown renderer. Matches recognises any markdown key, for consumers that ask "is this a markdown file?" rather than which source produced it.
public class MarkdownFormat
{
    /// Key for the first markdown source, and the standalone key for single-source hosts.
    
public static const string Key
; /// True when format is one of the markdown dispatch keys produced by SourceKey.
public static bool Matches(string format)
; /// Distinct dispatch key for the markdown source at index in registration order (index 0 keeps the bare Key).
public static string SourceKey(int index)
; }