DatabaseRepository

Trait DatabaseRepository 

Source
pub trait DatabaseRepository<DB: Database> {
    type Error: Error + Send + Sync + 'static;

    // Required method
    fn pool<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = &Pool<DB>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

数据库仓库特质 - 定义通用的数据库操作接口

Required Associated Types§

Source

type Error: Error + Send + Sync + 'static

Required Methods§

Source

fn pool<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = &Pool<DB>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Implementors§