#[non_exhaustive]pub struct UpdateWorkloadRequest {
pub workload: Option<Workload>,
pub update_mask: Option<FieldMask>,
/* private fields */
}Expand description
Request for Updating a workload.
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.workload: Option<Workload>Required. The workload to update.
The workload’s name field is used to identify the workload to be updated.
Format:
organizations/{org_id}/locations/{location_id}/workloads/{workload_id}
update_mask: Option<FieldMask>Required. The list of fields to be updated.
Implementations§
Source§impl UpdateWorkloadRequest
impl UpdateWorkloadRequest
pub fn new() -> Self
Sourcepub fn set_workload<T>(self, v: T) -> Self
pub fn set_workload<T>(self, v: T) -> Self
Sourcepub fn set_or_clear_workload<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_workload<T>(self, v: Option<T>) -> Self
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 = UpdateWorkloadRequest::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 = UpdateWorkloadRequest::new().set_or_clear_update_mask(Some(FieldMask::default()/* use setters */));
let x = UpdateWorkloadRequest::new().set_or_clear_update_mask(None::<FieldMask>);Trait Implementations§
Source§impl Clone for UpdateWorkloadRequest
impl Clone for UpdateWorkloadRequest
Source§fn clone(&self) -> UpdateWorkloadRequest
fn clone(&self) -> UpdateWorkloadRequest
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 UpdateWorkloadRequest
impl Debug for UpdateWorkloadRequest
Source§impl Default for UpdateWorkloadRequest
impl Default for UpdateWorkloadRequest
Source§fn default() -> UpdateWorkloadRequest
fn default() -> UpdateWorkloadRequest
Returns the “default value” for a type. Read more
Source§impl Message for UpdateWorkloadRequest
impl Message for UpdateWorkloadRequest
Source§impl PartialEq for UpdateWorkloadRequest
impl PartialEq for UpdateWorkloadRequest
impl StructuralPartialEq for UpdateWorkloadRequest
Auto Trait Implementations§
impl Freeze for UpdateWorkloadRequest
impl RefUnwindSafe for UpdateWorkloadRequest
impl Send for UpdateWorkloadRequest
impl Sync for UpdateWorkloadRequest
impl Unpin for UpdateWorkloadRequest
impl UnsafeUnpin for UpdateWorkloadRequest
impl UnwindSafe for UpdateWorkloadRequest
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