#[non_exhaustive]pub struct CustomPronunciationParams {
pub phrase: String,
pub phonetic_encoding: PhoneticEncoding,
pub pronunciation: String,
/* private fields */
}Available on crate features
conversation-profiles or conversations or environments or participants or sessions only.Expand description
Pronunciation customization for a phrase.
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.phrase: StringThe phrase to which the customization is applied. The phrase can be multiple words, such as proper nouns, but shouldn’t span the length of the sentence.
phonetic_encoding: PhoneticEncodingThe phonetic encoding of the phrase.
pronunciation: StringThe pronunciation of the phrase. This must be in the phonetic encoding specified above.
Implementations§
Source§impl CustomPronunciationParams
impl CustomPronunciationParams
pub fn new() -> Self
Sourcepub fn set_phrase<T: Into<String>>(self, v: T) -> Self
pub fn set_phrase<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_phonetic_encoding<T: Into<PhoneticEncoding>>(self, v: T) -> Self
pub fn set_phonetic_encoding<T: Into<PhoneticEncoding>>(self, v: T) -> Self
Sets the value of phonetic_encoding.
§Example
ⓘ
use google_cloud_dialogflow_v2::model::custom_pronunciation_params::PhoneticEncoding;
let x0 = CustomPronunciationParams::new().set_phonetic_encoding(PhoneticEncoding::Ipa);
let x1 = CustomPronunciationParams::new().set_phonetic_encoding(PhoneticEncoding::XSampa);Sourcepub fn set_pronunciation<T: Into<String>>(self, v: T) -> Self
pub fn set_pronunciation<T: Into<String>>(self, v: T) -> Self
Sets the value of pronunciation.
§Example
ⓘ
let x = CustomPronunciationParams::new().set_pronunciation("example");Trait Implementations§
Source§impl Clone for CustomPronunciationParams
impl Clone for CustomPronunciationParams
Source§fn clone(&self) -> CustomPronunciationParams
fn clone(&self) -> CustomPronunciationParams
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 CustomPronunciationParams
impl Debug for CustomPronunciationParams
Source§impl Default for CustomPronunciationParams
impl Default for CustomPronunciationParams
Source§fn default() -> CustomPronunciationParams
fn default() -> CustomPronunciationParams
Returns the “default value” for a type. Read more
Source§impl Message for CustomPronunciationParams
impl Message for CustomPronunciationParams
impl StructuralPartialEq for CustomPronunciationParams
Auto Trait Implementations§
impl Freeze for CustomPronunciationParams
impl RefUnwindSafe for CustomPronunciationParams
impl Send for CustomPronunciationParams
impl Sync for CustomPronunciationParams
impl Unpin for CustomPronunciationParams
impl UnsafeUnpin for CustomPronunciationParams
impl UnwindSafe for CustomPronunciationParams
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