pub trait OutputStorage<N: Network>: Clone + Sync {
    type IDMap: for<'a> Map<'a, N::TransitionID, Vec<Field<N>>>;
    type ReverseIDMap: for<'a> Map<'a, Field<N>, N::TransitionID>;
    type ConstantMap: for<'a> Map<'a, Field<N>, Option<Plaintext<N>>>;
    type PublicMap: for<'a> Map<'a, Field<N>, Option<Plaintext<N>>>;
    type PrivateMap: for<'a> Map<'a, Field<N>, Option<Ciphertext<N>>>;
    type RecordMap: for<'a> Map<'a, Field<N>, (Field<N>, Option<Record<N, Ciphertext<N>>>)>;
    type RecordNonceMap: for<'a> Map<'a, Group<N>, Field<N>>;
    type ExternalRecordMap: for<'a> Map<'a, Field<N>, ()>;

Show 18 methods fn open() -> Result<Self>; fn id_map(&self) -> &Self::IDMap; fn reverse_id_map(&self) -> &Self::ReverseIDMap; fn constant_map(&self) -> &Self::ConstantMap; fn public_map(&self) -> &Self::PublicMap; fn private_map(&self) -> &Self::PrivateMap; fn record_map(&self) -> &Self::RecordMap; fn record_nonce_map(&self) -> &Self::RecordNonceMap; fn external_record_map(&self) -> &Self::ExternalRecordMap; fn start_atomic(&self) { ... } fn is_atomic_in_progress(&self) -> bool { ... } fn abort_atomic(&self) { ... } fn finish_atomic(&self) -> Result<()> { ... } fn insert(
        &self,
        transition_id: N::TransitionID,
        outputs: &[Output<N>]
    ) -> Result<()> { ... } fn remove(&self, transition_id: &N::TransitionID) -> Result<()> { ... } fn find_transition_id(
        &self,
        output_id: &Field<N>
    ) -> Result<Option<N::TransitionID>> { ... } fn get_ids(&self, transition_id: &N::TransitionID) -> Result<Vec<Field<N>>> { ... } fn get(&self, transition_id: &N::TransitionID) -> Result<Vec<Output<N>>> { ... }
}
Expand description

A trait for transition output storage.

Required Associated Types

The mapping of transition ID to output IDs.

The mapping of output ID to transition ID.

The mapping of plaintext hash to (optional) plaintext.

The mapping of plaintext hash to (optional) plaintext.

The mapping of ciphertext hash to (optional) ciphertext.

The mapping of commitment to (checksum, (optional) record ciphertext).

The mapping of record nonce to commitment.

The mapping of external hash to (). Note: This is not the record commitment.

Required Methods

Initializes the transition output storage.

Returns the ID map.

Returns the reverse ID map.

Returns the constant map.

Returns the public map.

Returns the private map.

Returns the record map.

Returns the record nonce map.

Returns the external record map.

Provided Methods

Starts an atomic batch write operation.

Checks if an atomic batch is in progress.

Aborts an atomic batch write operation.

Finishes an atomic batch write operation.

Stores the given (transition ID, output) pair into storage.

Removes the output for the given transition ID.

Returns the transition ID that contains the given output ID.

Returns the output IDs for the given transition ID.

Returns the output for the given transition ID.

Implementors