pub trait ServerCopy {
// Required methods
fn name(&self) -> &'static str;
fn entries(&self) -> Vec<(&'static str, &LocalizedText)>;
fn entries_mut(&mut self) -> Vec<(&'static str, &mut LocalizedText)>;
// Provided method
fn translated(
self,
locale: impl Into<Locale>,
texts: &[(&str, &str)],
) -> Self
where Self: Sized { ... }
}Expand description
Copy a user reads, sentence by sentence, by the name of its field.
Required Methods§
Sourcefn entries(&self) -> Vec<(&'static str, &LocalizedText)>
fn entries(&self) -> Vec<(&'static str, &LocalizedText)>
Every sentence, by the name of its field.
Sourcefn entries_mut(&mut self) -> Vec<(&'static str, &mut LocalizedText)>
fn entries_mut(&mut self) -> Vec<(&'static str, &mut LocalizedText)>
Every sentence, to change in place.
Provided Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".