Trait barrel::generators::DatabaseGenerator [] [src]

pub trait DatabaseGenerator {
    fn create_table(name: &str) -> String;
fn create_table_if_not_exists(name: &str) -> String;
fn drop_table(name: &str) -> String;
fn drop_table_if_exists(name: &str) -> String;
fn rename_table(old: &str, new: &str) -> String;
fn alter_table(name: &str) -> String; }

A module which generates SQL syntax focused around generating basic SQL database statements

Required Methods

Create a new table with a name

Create a new table with a name, only if it doesn't exist

Drop a table with a name

Drop a table with a name, only if it exists

Rename a table from to

Modify a table in some other way

Implementors