#[non_exhaustive]pub struct AdaptationPhraseSet {
pub value: Option<Value>,
/* private fields */
}Expand description
A biasing PhraseSet, which can be either a string referencing the name of an existing PhraseSets resource, or an inline definition of a PhraseSet.
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.value: Option<Value>Implementations§
Source§impl AdaptationPhraseSet
impl AdaptationPhraseSet
pub fn new() -> Self
Sourcepub fn phrase_set(&self) -> Option<&String>
pub fn phrase_set(&self) -> Option<&String>
The value of value
if it holds a PhraseSet, None if the field is not set or
holds a different branch.
Sourcepub fn set_phrase_set<T: Into<String>>(self, v: T) -> Self
pub fn set_phrase_set<T: Into<String>>(self, v: T) -> Self
Sourcepub fn inline_phrase_set(&self) -> Option<&Box<PhraseSet>>
pub fn inline_phrase_set(&self) -> Option<&Box<PhraseSet>>
The value of value
if it holds a InlinePhraseSet, None if the field is not set or
holds a different branch.
Sourcepub fn set_inline_phrase_set<T: Into<Box<PhraseSet>>>(self, v: T) -> Self
pub fn set_inline_phrase_set<T: Into<Box<PhraseSet>>>(self, v: T) -> Self
Sets the value of value
to hold a InlinePhraseSet.
Note that all the setters affecting value are
mutually exclusive.
§Example
ⓘ
use google_cloud_speech_v2::model::PhraseSet;
let x = AdaptationPhraseSet::new().set_inline_phrase_set(PhraseSet::default()/* use setters */);
assert!(x.inline_phrase_set().is_some());
assert!(x.phrase_set().is_none());Trait Implementations§
Source§impl Clone for AdaptationPhraseSet
impl Clone for AdaptationPhraseSet
Source§fn clone(&self) -> AdaptationPhraseSet
fn clone(&self) -> AdaptationPhraseSet
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 AdaptationPhraseSet
impl Debug for AdaptationPhraseSet
Source§impl Default for AdaptationPhraseSet
impl Default for AdaptationPhraseSet
Source§fn default() -> AdaptationPhraseSet
fn default() -> AdaptationPhraseSet
Returns the “default value” for a type. Read more
Source§impl Message for AdaptationPhraseSet
impl Message for AdaptationPhraseSet
Source§impl PartialEq for AdaptationPhraseSet
impl PartialEq for AdaptationPhraseSet
impl StructuralPartialEq for AdaptationPhraseSet
Auto Trait Implementations§
impl Freeze for AdaptationPhraseSet
impl RefUnwindSafe for AdaptationPhraseSet
impl Send for AdaptationPhraseSet
impl Sync for AdaptationPhraseSet
impl Unpin for AdaptationPhraseSet
impl UnwindSafe for AdaptationPhraseSet
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