pub struct Store { /* private fields */ }Expand description
Store manages the .self folder and persistence operations.
Implementations§
Source§impl Store
impl Store
Sourcepub fn save(
&self,
project: &Project,
kind: &WorkspaceKind,
remote: Option<String>,
) -> OpsResult<()>
pub fn save( &self, project: &Project, kind: &WorkspaceKind, remote: Option<String>, ) -> OpsResult<()>
Save a project to the store.
Sourcepub fn save_manifest(&self, manifest: &Manifest) -> OpsResult<()>
pub fn save_manifest(&self, manifest: &Manifest) -> OpsResult<()>
Save the manifest to the store.
Sourcepub fn load_manifest(&self) -> OpsResult<Option<Manifest>>
pub fn load_manifest(&self) -> OpsResult<Option<Manifest>>
Load the manifest from the store.
Sourcepub fn save_graph(&self, graph: &SourceCodeGraph) -> OpsResult<PathBuf>
pub fn save_graph(&self, graph: &SourceCodeGraph) -> OpsResult<PathBuf>
Save a SourceCodeGraph to the store.
Sourcepub fn load_graph(&self) -> OpsResult<Option<SourceCodeGraph>>
pub fn load_graph(&self) -> OpsResult<Option<SourceCodeGraph>>
Load a SourceCodeGraph from the store.
Sourcepub fn list_snapshots(&self) -> OpsResult<Vec<PathBuf>>
pub fn list_snapshots(&self) -> OpsResult<Vec<PathBuf>>
List available snapshots.
Sourcepub fn load_snapshot(&self, path: &Path) -> OpsResult<Project>
pub fn load_snapshot(&self, path: &Path) -> OpsResult<Project>
Load a specific snapshot.
Sourcepub fn stats(&self) -> OpsResult<StoreStats>
pub fn stats(&self) -> OpsResult<StoreStats>
Get storage statistics.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Store
impl RefUnwindSafe for Store
impl Send for Store
impl Sync for Store
impl Unpin for Store
impl UnsafeUnpin for Store
impl UnwindSafe for Store
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more