#[non_exhaustive]pub struct CommonMetadata {
pub start_time: Option<Timestamp>,
pub end_time: Option<Timestamp>,
pub operation_type: OperationType,
pub labels: HashMap<String, String>,
pub state: State,
/* private fields */
}Expand description
Metadata common to all Datastore Admin operations.
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.start_time: Option<Timestamp>The time that work began on the operation.
end_time: Option<Timestamp>The time the operation ended, either successfully or otherwise.
operation_type: OperationTypeThe type of the operation. Can be used as a filter in ListOperationsRequest.
labels: HashMap<String, String>The client-assigned labels which were provided when the operation was created. May also include additional labels.
state: StateThe current state of the Operation.
Implementations§
Source§impl CommonMetadata
impl CommonMetadata
pub fn new() -> Self
Sourcepub fn set_start_time<T>(self, v: T) -> Self
pub fn set_start_time<T>(self, v: T) -> Self
Sets the value of start_time.
Sourcepub fn set_or_clear_start_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_start_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of start_time.
Sourcepub fn set_end_time<T>(self, v: T) -> Self
pub fn set_end_time<T>(self, v: T) -> Self
Sets the value of end_time.
Sourcepub fn set_or_clear_end_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_end_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of end_time.
Sourcepub fn set_operation_type<T: Into<OperationType>>(self, v: T) -> Self
pub fn set_operation_type<T: Into<OperationType>>(self, v: T) -> Self
Sets the value of operation_type.
Sourcepub fn set_labels<T, K, V>(self, v: T) -> Self
pub fn set_labels<T, K, V>(self, v: T) -> Self
Sets the value of labels.
Trait Implementations§
Source§impl Clone for CommonMetadata
impl Clone for CommonMetadata
Source§fn clone(&self) -> CommonMetadata
fn clone(&self) -> CommonMetadata
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 CommonMetadata
impl Debug for CommonMetadata
Source§impl Default for CommonMetadata
impl Default for CommonMetadata
Source§fn default() -> CommonMetadata
fn default() -> CommonMetadata
Returns the “default value” for a type. Read more
Source§impl Message for CommonMetadata
impl Message for CommonMetadata
Source§impl PartialEq for CommonMetadata
impl PartialEq for CommonMetadata
impl StructuralPartialEq for CommonMetadata
Auto Trait Implementations§
impl Freeze for CommonMetadata
impl RefUnwindSafe for CommonMetadata
impl Send for CommonMetadata
impl Sync for CommonMetadata
impl Unpin for CommonMetadata
impl UnwindSafe for CommonMetadata
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