pub struct VersionManager { /* private fields */ }Expand description
Version manager for catalogs
Implementations§
Source§impl VersionManager
impl VersionManager
Sourcepub fn create_version(
&mut self,
catalog_id: Uuid,
version: String,
description: Option<String>,
created_by: Option<Uuid>,
) -> CatalogVersion
pub fn create_version( &mut self, catalog_id: Uuid, version: String, description: Option<String>, created_by: Option<Uuid>, ) -> CatalogVersion
Create a new version
Sourcepub fn rollback_to_version(&mut self, version_id: Uuid) -> Result<(), String>
pub fn rollback_to_version(&mut self, version_id: Uuid) -> Result<(), String>
Rollback to a previous version
Sourcepub fn get_active_version(&self, catalog_id: Uuid) -> Option<&CatalogVersion>
pub fn get_active_version(&self, catalog_id: Uuid) -> Option<&CatalogVersion>
Get active version for a catalog
Sourcepub fn get_versions(&self, catalog_id: Uuid) -> Vec<&CatalogVersion>
pub fn get_versions(&self, catalog_id: Uuid) -> Vec<&CatalogVersion>
Get all versions for a catalog
Sourcepub fn compare_versions(
&self,
version_id_1: Uuid,
version_id_2: Uuid,
) -> Result<VersionDiff, String>
pub fn compare_versions( &self, version_id_1: Uuid, version_id_2: Uuid, ) -> Result<VersionDiff, String>
Compare two versions
Trait Implementations§
Auto Trait Implementations§
impl Freeze for VersionManager
impl RefUnwindSafe for VersionManager
impl Send for VersionManager
impl Sync for VersionManager
impl Unpin for VersionManager
impl UnwindSafe for VersionManager
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