Skip to main content

PromptSection

Trait PromptSection 

Source
pub trait PromptSection {
    const ID: &'static str;
    const VERSION: u32;
    const CONTENT_HASH: &'static str;
    const REQUIRED: bool;
    const PRIORITY: u16;

    // Required method
    fn render(&self) -> Result<RenderedSection>;
}
Expand description

The compile-time contract every generated section struct satisfies (system 23’s generated API).

Required Associated Constants§

Source

const ID: &'static str

Source

const VERSION: u32

Source

const CONTENT_HASH: &'static str

Source

const REQUIRED: bool

Source

const PRIORITY: u16

Required Methods§

Source

fn render(&self) -> Result<RenderedSection>

Deterministic rendering of this section with its typed values.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§