Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
D
dlib
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
钟尚武
dlib
Commits
8d1cf196
Commit
8d1cf196
authored
Sep 24, 2011
by
Davis King
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added missing asserts and clarified spec.
parent
5370c778
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
1 deletion
+19
-1
sqlite.h
dlib/sqlite/sqlite.h
+0
-0
sqlite_abstract.h
dlib/sqlite/sqlite_abstract.h
+19
-1
No files found.
dlib/sqlite/sqlite.h
View file @
8d1cf196
This diff is collapsed.
Click to expand it.
dlib/sqlite/sqlite_abstract.h
View file @
8d1cf196
...
...
@@ -23,7 +23,7 @@ namespace dlib
{
/*!
WHAT THIS OBJECT REPRESENTS
This is the exception object used by the
sql
ite tools to indicate
This is the exception object used by the
SQL
ite tools to indicate
that an error has occurred. An of the functions defined in this
file might throw this exception.
!*/
...
...
@@ -37,6 +37,11 @@ namespace dlib
WHAT THIS OBJECT REPRESENTS
This object is a C++ wrapper around a SQLite database connection
handle and therefore represents a SQLite database file.
Note that this wrapper is targeted at SQLite Version 3.
Note also that whenever SQLite indicates an error has occurred
this object will throw the sqlite_error exception.
!*/
public
:
...
...
@@ -52,6 +57,8 @@ namespace dlib
);
/*!
ensures
- opens the indicated database file or creates a new
database with the given name if one doesn't already exist.
- #get_database_filename() == file
- #is_open() == true
!*/
...
...
@@ -72,8 +79,14 @@ namespace dlib
);
/*!
ensures
- opens the indicated database file or creates a new
database with the given name if one doesn't already exist.
- #get_database_filename() == file
- #is_open() == true
- safely disposes of any previous SQLite database connection. If
any statement objects still exist which reference this database
then the SQLite database connection won't be fully closed
until those statement objects are also destroyed.
!*/
bool
is_open
(
...
...
@@ -119,6 +132,9 @@ namespace dlib
C++ wrapper around a SQLite prepared statement.
Note that whenever SQLite indicates an error has occurred this
object will throw the sqlite_error exception.
BINDABLE SQL PARAMETERS
Sometimes you want to execute a bunch of very similar SQL statements.
For example, you might need to execute many insert statements where each
...
...
@@ -158,6 +174,8 @@ namespace dlib
const
std
::
string
sql_statement
);
/*!
requires
- db.is_open() == true
ensures
- The given SQL statement can be executed against the given
database by calling exec().
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment