pub struct I18nConfig {
pub locales: Vec<String>,
pub default: String,
pub mode: String,
pub cache: bool,
pub route_hashes: HashMap<String, String>,
pub content_hashes: HashMap<String, HashMap<String, String>>,
pub messages: HashMap<String, HashMap<String, Value>>,
pub dist_dir: Option<PathBuf>,
}Expand description
Runtime i18n configuration loaded from build output.
Fields§
§locales: Vec<String>§default: String§mode: String§cache: bool§route_hashes: HashMap<String, String>Route pattern -> route hash (8 hex)
content_hashes: HashMap<String, HashMap<String, String>>Route hash -> { locale -> content hash (4 hex) }
messages: HashMap<String, HashMap<String, Value>>Memory mode: locale -> routeHash -> messages
dist_dir: Option<PathBuf>Paged mode: base directory for on-demand reads
Trait Implementations§
Source§impl Clone for I18nConfig
impl Clone for I18nConfig
Source§fn clone(&self) -> I18nConfig
fn clone(&self) -> I18nConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for I18nConfig
impl RefUnwindSafe for I18nConfig
impl Send for I18nConfig
impl Sync for I18nConfig
impl Unpin for I18nConfig
impl UnsafeUnpin for I18nConfig
impl UnwindSafe for I18nConfig
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