#[non_exhaustive]pub struct UpdatePhraseSetRequest {
pub phrase_set: Option<PhraseSet>,
pub update_mask: Option<FieldMask>,
pub validate_only: bool,
/* private fields */
}Expand description
Request message for the UpdatePhraseSet method.
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_set: Option<PhraseSet>Required. The PhraseSet to update.
The PhraseSet’s name field is used to identify the PhraseSet to update.
Format: projects/{project}/locations/{location}/phraseSets/{phrase_set}.
update_mask: Option<FieldMask>The list of fields to update. If empty, all non-default valued fields are
considered for update. Use * to update the entire PhraseSet resource.
validate_only: boolIf set, validate the request and preview the updated PhraseSet, but do not actually update it.
Implementations§
Source§impl UpdatePhraseSetRequest
impl UpdatePhraseSetRequest
pub fn new() -> Self
Sourcepub fn set_phrase_set<T>(self, v: T) -> Self
pub fn set_phrase_set<T>(self, v: T) -> Self
Sets the value of phrase_set.
§Example
ⓘ
use google_cloud_speech_v2::model::PhraseSet;
let x = UpdatePhraseSetRequest::new().set_phrase_set(PhraseSet::default()/* use setters */);Sourcepub fn set_or_clear_phrase_set<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_phrase_set<T>(self, v: Option<T>) -> Self
Sets or clears the value of phrase_set.
§Example
ⓘ
use google_cloud_speech_v2::model::PhraseSet;
let x = UpdatePhraseSetRequest::new().set_or_clear_phrase_set(Some(PhraseSet::default()/* use setters */));
let x = UpdatePhraseSetRequest::new().set_or_clear_phrase_set(None::<PhraseSet>);Sourcepub fn set_update_mask<T>(self, v: T) -> Self
pub fn set_update_mask<T>(self, v: T) -> Self
Sets the value of update_mask.
§Example
ⓘ
use wkt::FieldMask;
let x = UpdatePhraseSetRequest::new().set_update_mask(FieldMask::default()/* use setters */);Sourcepub fn set_or_clear_update_mask<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_update_mask<T>(self, v: Option<T>) -> Self
Sets or clears the value of update_mask.
§Example
ⓘ
use wkt::FieldMask;
let x = UpdatePhraseSetRequest::new().set_or_clear_update_mask(Some(FieldMask::default()/* use setters */));
let x = UpdatePhraseSetRequest::new().set_or_clear_update_mask(None::<FieldMask>);Sourcepub fn set_validate_only<T: Into<bool>>(self, v: T) -> Self
pub fn set_validate_only<T: Into<bool>>(self, v: T) -> Self
Sets the value of validate_only.
§Example
ⓘ
let x = UpdatePhraseSetRequest::new().set_validate_only(true);Trait Implementations§
Source§impl Clone for UpdatePhraseSetRequest
impl Clone for UpdatePhraseSetRequest
Source§fn clone(&self) -> UpdatePhraseSetRequest
fn clone(&self) -> UpdatePhraseSetRequest
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 UpdatePhraseSetRequest
impl Debug for UpdatePhraseSetRequest
Source§impl Default for UpdatePhraseSetRequest
impl Default for UpdatePhraseSetRequest
Source§fn default() -> UpdatePhraseSetRequest
fn default() -> UpdatePhraseSetRequest
Returns the “default value” for a type. Read more
Source§impl Message for UpdatePhraseSetRequest
impl Message for UpdatePhraseSetRequest
Source§impl PartialEq for UpdatePhraseSetRequest
impl PartialEq for UpdatePhraseSetRequest
impl StructuralPartialEq for UpdatePhraseSetRequest
Auto Trait Implementations§
impl Freeze for UpdatePhraseSetRequest
impl RefUnwindSafe for UpdatePhraseSetRequest
impl Send for UpdatePhraseSetRequest
impl Sync for UpdatePhraseSetRequest
impl Unpin for UpdatePhraseSetRequest
impl UnwindSafe for UpdatePhraseSetRequest
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