Trait maomi::locale_string::ToLocaleStr
source · pub trait ToLocaleStr {
// Required method
fn to_locale_str(&self) -> &str;
// Provided method
fn to_locale_string(&self) -> LocaleString { ... }
}
Expand description
Marker for a type that is i18n friendly.
When i18n support is enabled, only types which implemented this trait can be used in text node.
Required Methods§
sourcefn to_locale_str(&self) -> &str
fn to_locale_str(&self) -> &str
Get the translated text.
Provided Methods§
sourcefn to_locale_string(&self) -> LocaleString
fn to_locale_string(&self) -> LocaleString
Get the owned string of the translated text.