IndexWriteProvider

Trait IndexWriteProvider 

Source
pub trait IndexWriteProvider: StoreTransaction<TransactionErr = Self::Error> {
    type Error: Error;

    // Required methods
    fn register_contract(
        &mut self,
        contract_id: ContractId,
    ) -> Result<bool, Self::Error>;
    fn register_bundle(
        &mut self,
        bundle_id: BundleId,
        witness_id: Txid,
        contract_id: ContractId,
    ) -> Result<bool, IndexWriteError<Self::Error>>;
    fn register_operation(
        &mut self,
        opid: OpId,
        bundle_id: BundleId,
    ) -> Result<bool, IndexWriteError<Self::Error>>;
    fn register_spending(
        &mut self,
        opid: OpId,
        bundle_id: BundleId,
    ) -> Result<bool, IndexWriteError<Self::Error>>;
    fn index_genesis_assignments<State>(
        &mut self,
        contract_id: ContractId,
        vec: &[Assign<State, BlindSeal<Txid>>],
        opid: OpId,
        type_id: AssignmentType,
    ) -> Result<(), IndexWriteError<Self::Error>>
       where State: ExposedState;
    fn index_transition_assignments<State>(
        &mut self,
        contract_id: ContractId,
        vec: &[Assign<State, BlindSeal<TxPtr>>],
        opid: OpId,
        type_id: AssignmentType,
        witness_id: Txid,
    ) -> Result<(), IndexWriteError<Self::Error>>
       where State: ExposedState;
}

Required Associated Types§

Required Methods§

Source

fn register_contract( &mut self, contract_id: ContractId, ) -> Result<bool, Self::Error>

Source

fn register_bundle( &mut self, bundle_id: BundleId, witness_id: Txid, contract_id: ContractId, ) -> Result<bool, IndexWriteError<Self::Error>>

Source

fn register_operation( &mut self, opid: OpId, bundle_id: BundleId, ) -> Result<bool, IndexWriteError<Self::Error>>

Source

fn register_spending( &mut self, opid: OpId, bundle_id: BundleId, ) -> Result<bool, IndexWriteError<Self::Error>>

Source

fn index_genesis_assignments<State>( &mut self, contract_id: ContractId, vec: &[Assign<State, BlindSeal<Txid>>], opid: OpId, type_id: AssignmentType, ) -> Result<(), IndexWriteError<Self::Error>>
where State: ExposedState,

Source

fn index_transition_assignments<State>( &mut self, contract_id: ContractId, vec: &[Assign<State, BlindSeal<TxPtr>>], opid: OpId, type_id: AssignmentType, witness_id: Txid, ) -> Result<(), IndexWriteError<Self::Error>>
where State: ExposedState,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§