Rename SqliteConnection -> Connection.

Leave old name in as a (deprecated) typealias.
This commit is contained in:
John Gallagher
2015-12-12 13:50:12 -05:00
parent 87299009ba
commit 4327a84edb
10 changed files with 145 additions and 141 deletions

View File

@@ -8,7 +8,7 @@ use std::str;
use std::time::Duration;
use super::ffi;
use {SqliteError, SqliteResult, SqliteConnection};
use {SqliteError, SqliteResult, Connection};
/// Set up the process-wide SQLite error logging callback.
/// This function is marked unsafe for two reasons:
@@ -60,7 +60,7 @@ pub fn log(err_code: c_int, msg: &str) {
}
}
impl SqliteConnection {
impl Connection {
/// Register or clear a callback function that can be used for tracing the execution of SQL statements.
///
/// Prepared statement placeholders are replaced/logged with their assigned values.
@@ -120,7 +120,7 @@ mod test {
use std::sync::Mutex;
use std::time::Duration;
use SqliteConnection;
use Connection;
#[test]
fn test_trace() {
@@ -132,7 +132,7 @@ mod test {
traced_stmts.push(s.to_owned());
}
let mut db = SqliteConnection::open_in_memory().unwrap();
let mut db = Connection::open_in_memory().unwrap();
db.trace(Some(tracer));
{
let _ = db.query_row("SELECT ?", &[&1i32], |_| {});
@@ -160,7 +160,7 @@ mod test {
profiled.push((s.to_owned(), d));
}
let mut db = SqliteConnection::open_in_memory().unwrap();
let mut db = Connection::open_in_memory().unwrap();
db.profile(Some(profiler));
db.execute_batch("PRAGMA application_id = 1").unwrap();
db.profile(None);