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 under /_llms/. 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

BookCatalog Pennington.Book

Advertises each configured book as a DownloadLink. Derives the link list purely from BookOptions, PenningtonOptions, and LocalizationOptions — it never touches the site projection, so it is safe to resolve on the request path (the DocSite sidebar resolves it in MainLayout.OnInitializedAsync). The link label comes from the pennington.book.download translation when one is registered, falling back to "Download as PDF".

Constructors

BookCatalog

#
public BookCatalog(BookOptions options, PenningtonOptions penn, LocalizationOptions localization, TranslationOptions translations)

Creates the catalog over the configured book, localization, and translation options.

Parameters

options BookOptions
penn PenningtonOptions
localization LocalizationOptions
translations TranslationOptions

Methods

#
public IReadOnlyList<DownloadLink> GetLinks(string locale = null)

Returns the links available for locale (or the default locale when null), each with a locale-appropriate URL.

Parameters

locale string

Returns

IReadOnlyList<DownloadLink>

Pennington.Book.BookCatalog

namespace Pennington.Book;

/// Advertises each configured book as a DownloadLink. Derives the link list purely from BookOptions, PenningtonOptions, and LocalizationOptions — it never touches the site projection, so it is safe to resolve on the request path (the DocSite sidebar resolves it in MainLayout.OnInitializedAsync). The link label comes from the pennington.book.download translation when one is registered, falling back to "Download as PDF".
public class BookCatalog
{
    /// Creates the catalog over the configured book, localization, and translation options.
    
public BookCatalog(BookOptions options, PenningtonOptions penn, LocalizationOptions localization, TranslationOptions translations)
; /// Returns the links available for locale (or the default locale when null), each with a locale-appropriate URL.
public IReadOnlyList<DownloadLink> GetLinks(string locale = null)
; }