[][src]Trait rdbc::Driver

pub trait Driver: Sync + Send {
    fn connect(
        &self,
        url: &str
    ) -> Result<Rc<RefCell<dyn Connection + 'static>>>; }

Represents database driver that can be shared between threads, and can therefore implement a connection pool

Required methods

fn connect(&self, url: &str) -> Result<Rc<RefCell<dyn Connection + 'static>>>

Create a connection to the database. Note that connections are intended to be used in a single thread since most database connections are not thread-safe

Loading content...

Implementors

Loading content...