pub struct Registry<'reg> {
    pub env: Handlebars<'reg>,
    pub content: HashMap<String, Vec<u8>>,
}
Expand description

Registry with a cache for rendered item contents.

Fields

env: Handlebars<'reg>

The templates before rendering.

content: HashMap<String, Vec<u8>>

The rendered contents of items.

Trait Implementations

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Registers DT’s built-in helpers. Read more

Load templates and render them into cached storage, items that are not templated (see is_templated) will not be registered into templates but directly stored into the rendered cache. Read more

Returns the content of an item rendered with given rendering context. This does not modify the stored content. Read more

Updates the stored content of an item with the new content rendered with given rendering context. Read more

Looks up the rendered content of an item with given name.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.