pub struct PreparedWorktreeTransaction { /* private fields */ }Expand description
A durably staged create/delete/modify/rename transaction holding the root lock.
Implementations§
Source§impl PreparedWorktreeTransaction
impl PreparedWorktreeTransaction
Sourcepub fn commit(self) -> Result<WorktreeApplyReport, WorktreeError>
pub fn commit(self) -> Result<WorktreeApplyReport, WorktreeError>
Revalidates every path and atomically commits each unique slot in path order.
Sourcepub fn commit_retained(
self,
retention: UndoRetention,
) -> Result<RetainedApplyReport, WorktreeError>
pub fn commit_retained( self, retention: UndoRetention, ) -> Result<RetainedApplyReport, WorktreeError>
Commits like Self::commit while retaining exact undo evidence.
Backup artifacts survive the commit and a checksummed receipt bound to
this transaction is durably written before the final journal record, so
the committed state stays reversible through Worktree::rollback_undo.
Sourcepub fn abort(self) -> Result<AbortReport, WorktreeError>
pub fn abort(self) -> Result<AbortReport, WorktreeError>
Discards a prepared operation plan without changing a worktree path.
Source§impl PreparedWorktreeTransaction
impl PreparedWorktreeTransaction
pub fn transaction_id(&self) -> &str
pub const fn preview(&self) -> &WorktreeDryRunReport
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PreparedWorktreeTransaction
impl RefUnwindSafe for PreparedWorktreeTransaction
impl Send for PreparedWorktreeTransaction
impl Sync for PreparedWorktreeTransaction
impl Unpin for PreparedWorktreeTransaction
impl UnsafeUnpin for PreparedWorktreeTransaction
impl UnwindSafe for PreparedWorktreeTransaction
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