pub struct ModuleData {
pub name: &'static str,
pub domain: &'static str,
pub supported_languages: &'static [LanguageIdentifier],
pub namespaces: &'static [&'static str],
}Expand description
Static metadata describing an i18n module.
This single shape is shared by all managers (embedded, Bevy, and future third-party backends) so module discovery and routing can be standardized.
Fields§
§name: &'static strThe unique module name (typically crate name).
domain: &'static strThe Fluent domain for this module.
supported_languages: &'static [LanguageIdentifier]Languages that this module can provide.
namespaces: &'static [&'static str]Namespaces used by the module (e.g., “ui”, “errors”).
If empty, only the main {domain}.ftl file is used.
If non-empty, namespace files are the canonical resources and managers
treat {domain}.ftl as optional compatibility data.
Implementations§
Source§impl ModuleData
impl ModuleData
Sourcepub fn resource_plan(&self) -> Vec<ModuleResourceSpec>
pub fn resource_plan(&self) -> Vec<ModuleResourceSpec>
Returns the canonical resource plan for this module.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ModuleData
impl RefUnwindSafe for ModuleData
impl Send for ModuleData
impl Sync for ModuleData
impl Unpin for ModuleData
impl UnsafeUnpin for ModuleData
impl UnwindSafe for ModuleData
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more