[−][src]Trait oapth::Backend
A back end is the bridge between Rust and a database.
Required methods
fn create_oapth_tables<'a>(&'a mut self) -> BoxFut<'a, Result<()>>
Creates the necessary internal tables
fn delete_migrations<'a>(
&'a mut self,
version: i32,
mg: &'a MigrationGroup
) -> BoxFut<'a, Result<()>>
&'a mut self,
version: i32,
mg: &'a MigrationGroup
) -> BoxFut<'a, Result<()>>
Removes every migration of a given group mg
that is greater than version
.
fn execute<'a>(&'a mut self, command: &'a str) -> BoxFut<'a, Result<()>>
Executes arbitrary DDL or DML
fn insert_migrations<'a, I>(
&'a mut self,
migrations: I,
mg: &'a MigrationGroup
) -> BoxFut<'a, Result<()>> where
I: Clone + Iterator<Item = &'a Migration> + 'a,
&'a mut self,
migrations: I,
mg: &'a MigrationGroup
) -> BoxFut<'a, Result<()>> where
I: Clone + Iterator<Item = &'a Migration> + 'a,
Inserts a stream of migrations of a given group.
fn migrations<'a>(
&'a mut self,
mg: &'a MigrationGroup
) -> BoxFut<'a, Result<Vec<DbMigration>>>
&'a mut self,
mg: &'a MigrationGroup
) -> BoxFut<'a, Result<Vec<DbMigration>>>
Returns a vector with all migrations of a group within the database.
fn transaction<'a, I, S>(&'a mut self, commands: I) -> BoxFut<'a, Result<()>> where
I: Iterator<Item = S> + 'a,
S: AsRef<str>,
I: Iterator<Item = S> + 'a,
S: AsRef<str>,
Executes a stream of arbitrary DDL or DML inside a transaction.
Implementors
impl Backend for ()
[src]
fn create_oapth_tables<'a>(&'a mut self) -> BoxFut<'a, Result<()>>
[src]
fn execute<'a>(&'a mut self, _: &'a str) -> BoxFut<'a, Result<()>>
[src]
fn delete_migrations<'a>(
&'a mut self,
_: i32,
_: &'a MigrationGroup
) -> BoxFut<'a, Result<()>>
[src]
&'a mut self,
_: i32,
_: &'a MigrationGroup
) -> BoxFut<'a, Result<()>>
fn insert_migrations<'a, I>(
&'a mut self,
_: I,
_: &'a MigrationGroup
) -> BoxFut<'a, Result<()>> where
I: Clone + Iterator<Item = &'a Migration> + 'a,
[src]
&'a mut self,
_: I,
_: &'a MigrationGroup
) -> BoxFut<'a, Result<()>> where
I: Clone + Iterator<Item = &'a Migration> + 'a,
fn migrations<'a>(
&'a mut self,
_: &'a MigrationGroup
) -> BoxFut<'a, Result<Vec<DbMigration>>>
[src]
&'a mut self,
_: &'a MigrationGroup
) -> BoxFut<'a, Result<Vec<DbMigration>>>
fn transaction<'a, I, S>(&'a mut self, _: I) -> BoxFut<'a, Result<()>> where
I: Iterator<Item = S> + 'a,
S: AsRef<str>,
[src]
I: Iterator<Item = S> + 'a,
S: AsRef<str>,