pub struct WorkspaceMetadata {
pub name: String,
pub created_generation: u64,
pub saved_generation: u64,
pub app_version: String,
pub tags: BTreeMap<String, String>,
}Expand description
Workspace metadata for provenance and diagnostics.
Fields§
§name: StringHuman-readable workspace name.
created_generation: u64Monotonic generation counter (incremented on each save).
saved_generation: u64Last-saved generation counter.
app_version: StringApplication version that created/saved this workspace.
Forward-compatible custom tags.
Implementations§
Source§impl WorkspaceMetadata
impl WorkspaceMetadata
Sourcepub fn with_app_version(self, version: impl Into<String>) -> Self
pub fn with_app_version(self, version: impl Into<String>) -> Self
Set the application version.
Sourcepub fn increment_generation(&mut self)
pub fn increment_generation(&mut self)
Increment the save generation counter.
Trait Implementations§
Source§impl Clone for WorkspaceMetadata
impl Clone for WorkspaceMetadata
Source§fn clone(&self) -> WorkspaceMetadata
fn clone(&self) -> WorkspaceMetadata
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 WorkspaceMetadata
impl Debug for WorkspaceMetadata
Source§impl<'de> Deserialize<'de> for WorkspaceMetadata
impl<'de> Deserialize<'de> for WorkspaceMetadata
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for WorkspaceMetadata
impl PartialEq for WorkspaceMetadata
Source§impl Serialize for WorkspaceMetadata
impl Serialize for WorkspaceMetadata
impl Eq for WorkspaceMetadata
impl StructuralPartialEq for WorkspaceMetadata
Auto Trait Implementations§
impl Freeze for WorkspaceMetadata
impl RefUnwindSafe for WorkspaceMetadata
impl Send for WorkspaceMetadata
impl Sync for WorkspaceMetadata
impl Unpin for WorkspaceMetadata
impl UnsafeUnpin for WorkspaceMetadata
impl UnwindSafe for WorkspaceMetadata
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