# GetConnection in db_sqlx_maria::dev::prelude::dev - Rust
Get database connection

# Trait db_sqlx_maria::dev::prelude::dev::GetConnection

source ·

    pub trait GetConnection {
        type Conn;

        // Required method
        fn get_conn<'life0, 'async_trait>(
            &'life0 self
        ) -> Pin<Box<dyn Future<Output = Result<Self::Conn, DBError>> + Send + 'async_trait>>
           where 'life0: 'async_trait,
                 Self: 'async_trait;
    }

Expand description

Get database connection

## Required Associated Types§

source

#### type Conn

database connection type

## Required Methods§

source

#### fn get_conn<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Self::Conn, DBError>> + Send + 'async_trait>>
where 'life0: 'async_trait, Self: 'async_trait,

database specific error-type get connection from connection pool

## Implementors§