QueryTransaction

Trait QueryTransaction 

Source
pub trait QueryTransaction: MultiVersionQueryTransaction {
    type SingleVersionQuery<'a>: SingleVersionQueryTransaction
       where Self: 'a;
    type CdcQuery<'a>: CdcQueryTransaction
       where Self: 'a;

    // Required methods
    fn begin_single_query(&self) -> Result<Self::SingleVersionQuery<'_>>;
    fn begin_cdc_query(&self) -> Result<Self::CdcQuery<'_>>;

    // Provided methods
    fn with_single_query<F, R>(&self, f: F) -> Result<R>
       where F: FnOnce(&mut Self::SingleVersionQuery<'_>) -> Result<R> { ... }
    fn with_cdc_query<F, R>(&self, f: F) -> Result<R>
       where F: FnOnce(&mut Self::CdcQuery<'_>) -> Result<R> { ... }
}

Required Associated Types§

Required Methods§

Provided Methods§

Source

fn with_single_query<F, R>(&self, f: F) -> Result<R>
where F: FnOnce(&mut Self::SingleVersionQuery<'_>) -> Result<R>,

Source

fn with_cdc_query<F, R>(&self, f: F) -> Result<R>
where F: FnOnce(&mut Self::CdcQuery<'_>) -> Result<R>,

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§