pub struct Transaction<SP: StorageProvider, E> { /* private fields */ }Expand description
Transaction used to receive many commands at once.
The transaction allows us to have many temporary heads at once, so we don’t need as many merges when adding commands. When the transaction is committed, we will merge all temporary heads and the storage head, and then commit the result as the new storage head.
Implementations§
Source§impl<SP: StorageProvider, E: Engine> Transaction<SP, E>
impl<SP: StorageProvider, E: Engine> Transaction<SP, E>
Sourcepub fn storage_id(&self) -> GraphId
pub fn storage_id(&self) -> GraphId
Returns the transaction’s storage id.
Auto Trait Implementations§
impl<SP, E> Freeze for Transaction<SP, E>
impl<SP, E> RefUnwindSafe for Transaction<SP, E>
impl<SP, E> Send for Transaction<SP, E>
impl<SP, E> Sync for Transaction<SP, E>
impl<SP, E> Unpin for Transaction<SP, E>
impl<SP, E> UnwindSafe for Transaction<SP, E>
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