summaryrefslogtreecommitdiff
path: root/libsql/osqlmanager.h
authorzecke <zecke>2002-08-27 20:17:50 (UTC)
committer zecke <zecke>2002-08-27 20:17:50 (UTC)
commit86352e32f449ecf00de254674b7dcac72bc34a14 (patch) (side-by-side diff)
treeb5803b69ca00dceea1e2a76a5eee390f0748f27e /libsql/osqlmanager.h
parent1398b50ffc193bc9ab69ebe198aeda847c39516e (diff)
downloadopie-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
Diffstat (limited to 'libsql/osqlmanager.h') (more/less context) (ignore whitespace changes)
-rw-r--r--libsql/osqlmanager.h62
1 files changed, 62 insertions, 0 deletions
diff --git a/libsql/osqlmanager.h b/libsql/osqlmanager.h
new file mode 100644
index 0000000..b3d8d69
--- a/dev/null
+++ b/libsql/osqlmanager.h
@@ -0,0 +1,62 @@
+
+#ifndef OSQL_MANAGER_H
+#define OSQL_MANAGER_H
+
+#include <qobject.h>
+
+#include "osqlbackend.h"
+
+/**
+ * OSQLManager is responsible for loading
+ * and unloading, querying different OSQL
+ * services
+ * Load a OSQLDriver and delete it yourself
+ *
+ */
+class OSQLDriver;
+class OSQLManager : public QObject {
+ Q_OBJECT
+public:
+ /**
+ * Empty c'tor
+ */
+ OSQLManager();
+
+ /**
+ * Query the Manager for different backends
+ */
+ OSQLBackEnd::ValueList queryBackEnd();
+
+ /**
+ * Load a backend with it's name from param name
+ */
+ OSQLDriver* load( const QString& name );
+
+ /**
+ * Load a OSQLDevice from const reference of OSQLBackEnd
+ */
+ OSQLDriver* load( const OSQLBackEnd& );
+
+ /**
+ * loads the Opie standard backend
+ */
+ OSQLDriver *standard();
+
+ /**
+ * register path to the search path list
+ * When querying for services we scan all the
+ * registered path for backends
+ */
+ void registerPath( const QString& path );
+
+ /**
+ * unregisterPath from the search path list
+ */
+ bool unregisterPath( const QString& path );
+private:
+ OSQLBackEnd::ValueList builtIn()const;
+ OSQLBackEnd::ValueList m_list;
+ QStringList m_path;
+};
+
+#endif