blob: 8d19ff229d0ac083f1bf963043643dcf13f6f276 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
/***************************************************************************
* Copyright (C) 2005 by *
* Jason Kivlighn ([email protected]) *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
***************************************************************************/
#ifndef QSQL_SQLITE_H
#define QSQL_SQLITE_H
#include <qsqldriver.h>
#include <qsqlresult.h>
#include <qsqlrecord.h>
#include <qsqlindex.h>
typedef QVariant QSqlVariant;
class QSQLiteDB;
class KreSQLiteDriver : public QSqlDriver
{
public:
KreSQLiteDriver(QObject * parent = 0, const char * name = 0);
KreSQLiteDriver(QSQLiteDB *connection, QObject *parent = 0, const char *name = 0);
~KreSQLiteDriver();
bool hasFeature( DriverFeature ) const;
bool open( const QString&,
const QString&,
const QString&,
const QString&,
int );
void close();
QSqlQuery createQuery() const;
bool beginTransaction();
bool commitTransaction();
bool rollbackTransaction();
QStringList tables(const QString &typeName) const;
QSqlIndex primaryIndex(const QString &tblname) const;
//QSqlRecordInfo recordInfo(const QString &tbl) const;
//QSqlRecord record(const QString &tblname) const;
//QString formatValue( const QSqlField* field, bool trimStrings ) const;
private:
friend class KreSQLiteResult;
QSQLiteDB *db;
};
#endif
|