This site provides a machine-readable index at /llms.txt.

Skip to main content Skip to navigation

ContentPipeline Pennington.Pipeline

Orchestrates the content processing pipeline.

Constructors

.ctor

#
public ContentPipeline(
    IEnumerable<IContentService> services,
    IContentParser parser,
    IContentRenderer renderer);

Creates the pipeline from the registered content services, parser, and renderer.

Parameters

services IEnumerable<IContentService>
parser IContentParser
renderer IContentRenderer

Methods

DiscoverAsync

#
public async IAsyncEnumerable<ContentItem> DiscoverAsync();

Entry: content services produce discovered items.

Returns

IAsyncEnumerable<ContentItem>

GenerateAsync

#
public async Task<BuildReport> GenerateAsync(IAsyncEnumerable<ContentItem> items, OutputOptions options);

Exit: generate output files.

Parameters

items IAsyncEnumerable<ContentItem>
options OutputOptions

Returns

Task<BuildReport>

ParseAsync

#
public async IAsyncEnumerable<ContentItem> ParseAsync(IAsyncEnumerable<ContentItem> items);

Transform: parse items (read files, extract YAML + body).

Parameters

items IAsyncEnumerable<ContentItem>

Returns

IAsyncEnumerable<ContentItem>

RenderAsync

#
public async IAsyncEnumerable<ContentItem> RenderAsync(IAsyncEnumerable<ContentItem> items);

Transform: render items (Markdig pipeline to HTML).

Parameters

items IAsyncEnumerable<ContentItem>

Returns

IAsyncEnumerable<ContentItem>

RunAsync

#
public async Task<BuildReport> RunAsync(OutputOptions options);

Convenience: run the full pipeline end-to-end.

Parameters

options OutputOptions

Returns

Task<BuildReport>

Pennington.Pipeline.ContentPipeline

namespace Pennington.Pipeline;

/// Orchestrates the content processing pipeline.
public class ContentPipeline
{
    /// Creates the pipeline from the registered content services, parser, and renderer.
    
public ContentPipeline(
    IEnumerable<IContentService> services,
    IContentParser parser,
    IContentRenderer renderer);
/// Entry: content services produce discovered items.
public async IAsyncEnumerable<ContentItem> DiscoverAsync();
/// Exit: generate output files.
public async Task<BuildReport> GenerateAsync(IAsyncEnumerable<ContentItem> items, OutputOptions options);
/// Transform: parse items (read files, extract YAML + body).
public async IAsyncEnumerable<ContentItem> ParseAsync(IAsyncEnumerable<ContentItem> items);
/// Transform: render items (Markdig pipeline to HTML).
public async IAsyncEnumerable<ContentItem> RenderAsync(IAsyncEnumerable<ContentItem> items);
/// Convenience: run the full pipeline end-to-end.
public async Task<BuildReport> RunAsync(OutputOptions options);
}