pub struct ReadonlyRepo { /* private fields */ }Implementations§
Source§impl ReadonlyRepo
impl ReadonlyRepo
pub fn default_op_store_factory() -> impl FnOnce(&Path) -> Box<dyn OpStore>
pub fn default_op_heads_store_factory() -> impl FnOnce(&Path, &Arc<dyn OpStore>, &View, OperationMetadata) -> (Box<dyn OpHeadsStore>, Operation)
pub fn init( user_settings: &UserSettings, repo_path: &Path, backend_factory: impl FnOnce(&Path) -> Box<dyn Backend>, op_store_factory: impl FnOnce(&Path) -> Box<dyn OpStore>, op_heads_store_factory: impl FnOnce(&Path, &Arc<dyn OpStore>, &View, OperationMetadata) -> (Box<dyn OpHeadsStore>, Operation), ) -> Result<Arc<ReadonlyRepo>, PathError>
pub fn load_at_head( user_settings: &UserSettings, repo_path: &Path, store_factories: &StoreFactories, ) -> Result<Arc<ReadonlyRepo>, OpHeadResolutionError<BackendError>>
pub fn loader(&self) -> RepoLoader
pub fn repo_path(&self) -> &PathBuf
pub fn op_id(&self) -> &OperationId
pub fn operation(&self) -> &Operation
pub fn view(&self) -> &View
pub fn readonly_index(&self) -> &Arc<ReadonlyIndex> ⓘ
pub fn op_heads_store(&self) -> &Arc<dyn OpHeadsStore> ⓘ
pub fn index_store(&self) -> &Arc<IndexStore> ⓘ
pub fn settings(&self) -> &RepoSettings
pub fn start_transaction( self: &Arc<ReadonlyRepo>, user_settings: &UserSettings, description: &str, ) -> Transaction
pub fn reload_at_head( &self, user_settings: &UserSettings, ) -> Result<Arc<ReadonlyRepo>, OpHeadResolutionError<BackendError>>
pub fn reload_at(&self, operation: &Operation) -> Arc<ReadonlyRepo> ⓘ
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for ReadonlyRepo
impl !RefUnwindSafe for ReadonlyRepo
impl !UnwindSafe for ReadonlyRepo
impl Send for ReadonlyRepo
impl Sync for ReadonlyRepo
impl Unpin for ReadonlyRepo
impl UnsafeUnpin for ReadonlyRepo
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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