Trait butane_core::db::BackendConnection
source · pub trait BackendConnection: ConnectionMethods + Debug + Send + 'static {
// Required methods
fn transaction(&mut self) -> Result<Transaction<'_>>;
fn backend(&self) -> Box<dyn Backend>;
fn backend_name(&self) -> &'static str;
fn is_closed(&self) -> bool;
}
Expand description
Database connection.
Required Methods§
sourcefn transaction(&mut self) -> Result<Transaction<'_>>
fn transaction(&mut self) -> Result<Transaction<'_>>
Begin a database transaction. The transaction object must be used in place of this connection until it is committed and aborted.