Lines Matching refs:db_
30 : db_(db) { in ScopedBusyTimeout()
33 sqlite3_busy_timeout(db_, 0); in ~ScopedBusyTimeout()
38 return sqlite3_busy_timeout(db_, in SetTimeout()
43 sqlite3* db_; member in __anon7ff78dfa0111::ScopedBusyTimeout
89 : db_(NULL), in Connection()
116 if (db_) { in Close()
117 sqlite3_close(db_); in Close()
118 db_ = NULL; in Close()
123 if (!db_) { in Preload()
140 sqlite3_preload(db_); in Preload()
206 if (!db_) in Execute()
208 return sqlite3_exec(db_, sql, NULL, NULL, NULL) == SQLITE_OK; in Execute()
212 if (!db_) in ExecuteWithTimeout()
215 ScopedBusyTimeout busy_timeout(db_); in ExecuteWithTimeout()
217 return sqlite3_exec(db_, sql, NULL, NULL, NULL) == SQLITE_OK; in ExecuteWithTimeout()
246 if (!db_) in GetUniqueStatement()
250 if (sqlite3_prepare_v2(db_, sql, -1, &stmt, NULL) != SQLITE_OK) { in GetUniqueStatement()
291 if (!db_) { in GetLastInsertRowId()
295 return sqlite3_last_insert_rowid(db_); in GetLastInsertRowId()
299 if (!db_) { in GetLastChangeCount()
303 return sqlite3_changes(db_); in GetLastChangeCount()
307 if (!db_) in GetErrorCode()
309 return sqlite3_errcode(db_); in GetErrorCode()
313 if (!db_) in GetLastErrno()
317 if (SQLITE_OK != sqlite3_file_control(db_, NULL, SQLITE_LAST_ERRNO, &err)) in GetLastErrno()
324 if (!db_) in GetErrorMessage()
326 return sqlite3_errmsg(db_); in GetErrorMessage()
330 if (db_) { in OpenInternal()
335 int err = sqlite3_open(file_name.c_str(), &db_); in OpenInternal()
338 db_ = NULL; in OpenInternal()
347 err = sqlite3_extended_result_codes(db_, 1); in OpenInternal()