#[non_exhaustive]pub struct TranslationConfig {
pub target_language: String,
/* private fields */
}Expand description
Translation configuration. Use to translate the given audio into text for the desired language.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.target_language: StringRequired. The language code to translate to.
Implementations§
Source§impl TranslationConfig
impl TranslationConfig
pub fn new() -> Self
Sourcepub fn set_target_language<T: Into<String>>(self, v: T) -> Self
pub fn set_target_language<T: Into<String>>(self, v: T) -> Self
Sets the value of target_language.
§Example
ⓘ
let x = TranslationConfig::new().set_target_language("example");Trait Implementations§
Source§impl Clone for TranslationConfig
impl Clone for TranslationConfig
Source§fn clone(&self) -> TranslationConfig
fn clone(&self) -> TranslationConfig
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 moreSource§impl Debug for TranslationConfig
impl Debug for TranslationConfig
Source§impl Default for TranslationConfig
impl Default for TranslationConfig
Source§fn default() -> TranslationConfig
fn default() -> TranslationConfig
Returns the “default value” for a type. Read more
Source§impl Message for TranslationConfig
impl Message for TranslationConfig
Source§impl PartialEq for TranslationConfig
impl PartialEq for TranslationConfig
impl StructuralPartialEq for TranslationConfig
Auto Trait Implementations§
impl Freeze for TranslationConfig
impl RefUnwindSafe for TranslationConfig
impl Send for TranslationConfig
impl Sync for TranslationConfig
impl Unpin for TranslationConfig
impl UnwindSafe for TranslationConfig
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