[][src]Module fluent_templates::loader

This modules contains both the static_loader and ArcLoader implementations, as well as the Loader trait. Which provides a loader agnostic interface.

Macros

langid
langids

Structs

ArcLoader

A loader that uses Arc<FluentResource> as its backing storage. This is mainly useful for when you need to load fluent at run time. You can configure the initialisation with ArcLoaderBuilder.

ArcLoaderBuilder

A builder pattern struct for constructing ArcLoaders.

LanguageIdentifier

LanguageIdentifier is a core struct representing a Unicode Language Identifier.

StaticLoader

A simple Loader implementation, with statically-loaded fluent data. Typically created with the [static_loader!()] macro

Traits

Loader

A loader capable of looking up Fluent keys given a language.

Functions

build_bundles

Maps from map of languages containing a list of resources to a map of languages containing a FluentBundle of those resources.

build_fallbacks

Constructs a map of languages with a list of potential fallback languages.

build_resources

Builds a map of languages and their available resources based on dir.

create_bundle

Creates a new static FluentBundle for lang using resources. Optionally shared resources can be specified with core_resource and the bundle can be customized with customizer.

load_core_resource

Attempts to load a core resource and panicks if not found.