#[non_exhaustive]pub struct UpdateModelRequest {
pub model: Option<Model>,
pub update_mask: Option<FieldMask>,
/* private fields */
}Available on crate feature
model-service only.Expand description
Request message for ModelService.UpdateModel.
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.model: Option<Model>Required. The Model which replaces the resource on the server. When Model Versioning is enabled, the model.name will be used to determine whether to update the model or model version.
- model.name with the @ value, e.g. models/123@1, refers to a version specific update.
- model.name without the @ value, e.g. models/123, refers to a model update.
- model.name with @-, e.g. models/123@-, refers to a model update.
- Supported model fields: display_name, description; supported version-specific fields: version_description. Labels are supported in both scenarios. Both the model labels and the version labels are merged when a model is returned. When updating labels, if the request is for model-specific update, model label gets updated. Otherwise, version labels get updated.
- A model name or model version name fields update mismatch will cause a precondition error.
- One request cannot update both the model and the version fields. You must update them separately.
update_mask: Option<FieldMask>Required. The update mask applies to the resource.
For the FieldMask definition, see
google.protobuf.FieldMask.
Implementations§
Source§impl UpdateModelRequest
impl UpdateModelRequest
pub fn new() -> Self
Sourcepub fn set_or_clear_model<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_model<T>(self, v: Option<T>) -> Self
Sets or clears the value of model.
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.
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.
Trait Implementations§
Source§impl Clone for UpdateModelRequest
impl Clone for UpdateModelRequest
Source§fn clone(&self) -> UpdateModelRequest
fn clone(&self) -> UpdateModelRequest
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 UpdateModelRequest
impl Debug for UpdateModelRequest
Source§impl Default for UpdateModelRequest
impl Default for UpdateModelRequest
Source§fn default() -> UpdateModelRequest
fn default() -> UpdateModelRequest
Returns the “default value” for a type. Read more
Source§impl Message for UpdateModelRequest
impl Message for UpdateModelRequest
Source§impl PartialEq for UpdateModelRequest
impl PartialEq for UpdateModelRequest
impl StructuralPartialEq for UpdateModelRequest
Auto Trait Implementations§
impl Freeze for UpdateModelRequest
impl RefUnwindSafe for UpdateModelRequest
impl Send for UpdateModelRequest
impl Sync for UpdateModelRequest
impl Unpin for UpdateModelRequest
impl UnwindSafe for UpdateModelRequest
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