clean up use of modules

This commit is contained in:
Andy Grove 2018-10-06 10:04:22 -06:00
parent 661ada0664
commit beb1a7a735
3 changed files with 23 additions and 40 deletions

18
src/dialect/mod.rs Normal file
View file

@ -0,0 +1,18 @@
mod ansi_sql;
mod generic_sql;
pub mod keywords;
mod postgresql;
pub use self::ansi_sql::AnsiSqlDialect;
pub use self::generic_sql::GenericSqlDialect;
pub use self::postgresql::PostgreSqlDialect;
pub trait Dialect {
/// Get a list of keywords for this dialect
fn keywords(&self) -> Vec<&'static str>;
/// Determine if a character is a valid identifier start character
fn is_identifier_start(&self, ch: char) -> bool;
/// Determine if a character is a valid identifier character
fn is_identifier_part(&self, ch: char) -> bool;
}