/sqlite3cc

To get this branch, use:
bzr branch http://bzr.ed.am/sqlite3cc

« back to all changes in this revision

Viewing changes to include/sqlite3cc/database.h

  • Committer: edam
  • Date: 2010-07-29 06:39:13 UTC
  • Revision ID: edam@waxworlds.org-20100729063913-wvcvkogsa2alwkhr
- moved basic_statement::operator <<() back to basic_statement and just create another specialisation in command so that it can use sqlite::exec

Show diffs side-by-side

added added

removed removed

Lines of Context:
34
34
 
35
35
 
36
36
class basic_statement;
37
 
class transaction;
 
37
class basic_transaction;
38
38
 
39
39
 
40
40
class database
98
98
 
99
99
//______________________________________________________________________________
100
100
//                                                                implementation
101
 
private:
 
101
protected:
102
102
 
103
103
        friend class basic_statement;
 
104
        friend class basic_transaction;
104
105
        friend class command;
 
106
        friend class query;
 
107
        friend class sqlite_error;
 
108
 
 
109
        /** class to provide a scope lock for the database mutex */
 
110
        class database_mutex_guard
 
111
        {
 
112
        public:
 
113
 
 
114
                /** constructor that provides a database */
 
115
                database_mutex_guard(
 
116
                        database &database );
 
117
 
 
118
                ~database_mutex_guard();
 
119
 
 
120
                /** release the mutex early */
 
121
                void leave();
 
122
 
 
123
        private:
 
124
                sqlite3_mutex *_mutex;
 
125
        };
 
126
 
 
127
private:
105
128
 
106
129
        /** the database handle */
107
130
        sqlite3 *_handle;