Struct snarkvm_ledger_store::helpers::memory::TransactionMemory
source · pub struct TransactionMemory<N: Network> { /* private fields */ }
Expand description
An in-memory transaction storage.
Trait Implementations§
source§impl<N: Clone + Network> Clone for TransactionMemory<N>where
N::TransactionID: Clone,
impl<N: Clone + Network> Clone for TransactionMemory<N>where N::TransactionID: Clone,
source§fn clone(&self) -> TransactionMemory<N>
fn clone(&self) -> TransactionMemory<N>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<N: Network> TransactionStorage<N> for TransactionMemory<N>
impl<N: Network> TransactionStorage<N> for TransactionMemory<N>
source§fn open(
transition_store: TransitionStore<N, Self::TransitionStorage>
) -> Result<Self>
fn open( transition_store: TransitionStore<N, Self::TransitionStorage> ) -> Result<Self>
Initializes the transaction storage.
source§fn deployment_store(&self) -> &DeploymentStore<N, Self::DeploymentStorage>
fn deployment_store(&self) -> &DeploymentStore<N, Self::DeploymentStorage>
Returns the deployment store.
source§fn execution_store(&self) -> &ExecutionStore<N, Self::ExecutionStorage>
fn execution_store(&self) -> &ExecutionStore<N, Self::ExecutionStorage>
Returns the execution store.
source§fn fee_store(&self) -> &FeeStore<N, Self::FeeStorage>
fn fee_store(&self) -> &FeeStore<N, Self::FeeStorage>
Returns the fee store.
§type IDMap = MemoryMap<<N as Network>::TransactionID, TransactionType>
type IDMap = MemoryMap<<N as Network>::TransactionID, TransactionType>
The mapping of
transaction ID
to transaction type
.§type DeploymentStorage = DeploymentMemory<N>
type DeploymentStorage = DeploymentMemory<N>
The deployment storage.
§type ExecutionStorage = ExecutionMemory<N>
type ExecutionStorage = ExecutionMemory<N>
The execution storage.
§type FeeStorage = FeeMemory<N>
type FeeStorage = FeeMemory<N>
The fee storage.
§type TransitionStorage = TransitionMemory<N>
type TransitionStorage = TransitionMemory<N>
The transition storage.
source§fn transition_store(&self) -> &TransitionStore<N, Self::TransitionStorage>
fn transition_store(&self) -> &TransitionStore<N, Self::TransitionStorage>
Returns the transition store.
source§fn start_atomic(&self)
fn start_atomic(&self)
Starts an atomic batch write operation.
source§fn is_atomic_in_progress(&self) -> bool
fn is_atomic_in_progress(&self) -> bool
Checks if an atomic batch is in progress.
source§fn atomic_checkpoint(&self)
fn atomic_checkpoint(&self)
Checkpoints the atomic batch.
source§fn clear_latest_checkpoint(&self)
fn clear_latest_checkpoint(&self)
Clears the latest atomic batch checkpoint.
source§fn atomic_rewind(&self)
fn atomic_rewind(&self)
Rewinds the atomic batch to the previous checkpoint.
source§fn abort_atomic(&self)
fn abort_atomic(&self)
Aborts an atomic batch write operation.
source§fn finish_atomic(&self) -> Result<()>
fn finish_atomic(&self) -> Result<()>
Finishes an atomic batch write operation.
source§fn insert(&self, transaction: &Transaction<N>) -> Result<()>
fn insert(&self, transaction: &Transaction<N>) -> Result<()>
Stores the given
transaction
into storage.source§fn remove(&self, transaction_id: &N::TransactionID) -> Result<()>
fn remove(&self, transaction_id: &N::TransactionID) -> Result<()>
Removes the transaction for the given
transaction ID
.source§fn find_transaction_id_from_transition_id(
&self,
transition_id: &N::TransitionID
) -> Result<Option<N::TransactionID>>
fn find_transaction_id_from_transition_id( &self, transition_id: &N::TransitionID ) -> Result<Option<N::TransactionID>>
Returns the transaction ID that contains the given
transition ID
.source§fn find_transaction_id_from_program_id(
&self,
program_id: &ProgramID<N>
) -> Result<Option<N::TransactionID>>
fn find_transaction_id_from_program_id( &self, program_id: &ProgramID<N> ) -> Result<Option<N::TransactionID>>
Returns the transaction ID that contains the given
program ID
.source§fn get_transaction(
&self,
transaction_id: &N::TransactionID
) -> Result<Option<Transaction<N>>>
fn get_transaction( &self, transaction_id: &N::TransactionID ) -> Result<Option<Transaction<N>>>
Returns the transaction for the given
transaction ID
.Auto Trait Implementations§
impl<N> !RefUnwindSafe for TransactionMemory<N>
impl<N> Send for TransactionMemory<N>
impl<N> Sync for TransactionMemory<N>
impl<N> Unpin for TransactionMemory<N>where N: Unpin,
impl<N> !UnwindSafe for TransactionMemory<N>
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