author | zecke <zecke> | 2002-08-27 20:17:50 (UTC) |
---|---|---|
committer | zecke <zecke> | 2002-08-27 20:17:50 (UTC) |
commit | 86352e32f449ecf00de254674b7dcac72bc34a14 (patch) (unidiff) | |
tree | b5803b69ca00dceea1e2a76a5eee390f0748f27e /libsql/osqlbackend.h | |
parent | 1398b50ffc193bc9ab69ebe198aeda847c39516e (diff) | |
download | opie-86352e32f449ecf00de254674b7dcac72bc34a14.zip opie-86352e32f449ecf00de254674b7dcac72bc34a14.tar.gz opie-86352e32f449ecf00de254674b7dcac72bc34a14.tar.bz2 |
Initial check in of the light wrapper library
around normal SQL
The first driver implementation is a SQLite version
-rw-r--r-- | libsql/osqlbackend.h | 75 |
1 files changed, 75 insertions, 0 deletions
diff --git a/libsql/osqlbackend.h b/libsql/osqlbackend.h new file mode 100644 index 0000000..ad879a4 --- a/dev/null +++ b/libsql/osqlbackend.h | |||
@@ -0,0 +1,75 @@ | |||
1 | |||
2 | #ifndef OSQL_BACKEND_H | ||
3 | #define OSQL_BACKEND_H | ||
4 | |||
5 | #include <qcstring.h> | ||
6 | #include <qstring.h> | ||
7 | #include <qvaluelist.h> | ||
8 | |||
9 | /** | ||
10 | * OSQLBackEnd represents an available backend | ||
11 | * to the Opie Database Service | ||
12 | * It's used to easily extend OSQL services by | ||
13 | * 3rd party plugins. | ||
14 | * It's used to show | ||
15 | */ | ||
16 | class OSQLBackEnd /*: public QShared */ { | ||
17 | public: | ||
18 | typedef QValueList<OSQLBackEnd> ValueList; | ||
19 | /** | ||
20 | * A basic c'tor | ||
21 | * @param name the user visible name of the service | ||
22 | * @param vendor the vendor of the service | ||
23 | * @param license the license of the service | ||
24 | * @param library what is the name of lib if builtin it's builtin | ||
25 | */ | ||
26 | OSQLBackEnd( const QString& name = QString::null, | ||
27 | const QString& vendor = QString::null, | ||
28 | const QString& license = QString::null, | ||
29 | const QCString& library = QCString() ); | ||
30 | OSQLBackEnd( const OSQLBackEnd& ); | ||
31 | OSQLBackEnd &operator=( const OSQLBackEnd& ); | ||
32 | bool operator==(const OSQLBackEnd& ); | ||
33 | |||
34 | ~OSQLBackEnd(); | ||
35 | |||
36 | /** @return the name */ | ||
37 | QString name()const; | ||
38 | |||
39 | /** @return the vendor */ | ||
40 | QString vendor()const; | ||
41 | |||
42 | /** @return the license */ | ||
43 | QString license()const; | ||
44 | |||
45 | /** @return the name of the library */ | ||
46 | QCString library() const; | ||
47 | |||
48 | bool isDefault()const; | ||
49 | int preference()const; | ||
50 | |||
51 | /** @param name the name to set */ | ||
52 | void setName( const QString& name ); | ||
53 | |||
54 | /** @param vendor the vendor to set */ | ||
55 | void setVendor( const QString& vendor ); | ||
56 | |||
57 | /** @param license the license applied */ | ||
58 | void setLicense( const QString& license ); | ||
59 | |||
60 | /** @param the lib to set */ | ||
61 | void setLibrary( const QCString& lib ); | ||
62 | |||
63 | void setDefault( bool ); | ||
64 | void setPreference( int ); | ||
65 | |||
66 | private: | ||
67 | QString m_name; | ||
68 | QString m_vendor; | ||
69 | QString m_license; | ||
70 | QCString m_lib; | ||
71 | bool m_default :1; | ||
72 | int m_pref; | ||
73 | }; | ||
74 | |||
75 | #endif | ||