kexi

kexidbdrivermanager.h

00001 /***************************************************************************
00002  * kexidbdrivermanager.h
00003  * This file is part of the KDE project
00004  * copyright (C)2004-2005 by Sebastian Sauer (mail@dipe.org)
00005  *
00006  * This program is free software; you can redistribute it and/or
00007  * modify it under the terms of the GNU Library General Public
00008  * License as published by the Free Software Foundation; either
00009  * version 2 of the License, or (at your option) any later version.
00010  * This program is distributed in the hope that it will be useful,
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00013  * Library General Public License for more details.
00014  * You should have received a copy of the GNU Library General Public License
00015  * along with this program; see the file COPYING.  If not, write to
00016  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00017  * Boston, MA 02110-1301, USA.
00018  ***************************************************************************/
00019 
00020 #ifndef KROSS_KEXIDB_KEXIDBDRIVERMANAGER_H
00021 #define KROSS_KEXIDB_KEXIDBDRIVERMANAGER_H
00022 
00023 #include <qstring.h>
00024 
00025 #include <api/object.h>
00026 #include <api/variant.h>
00027 #include <api/list.h>
00028 #include <api/class.h>
00029 
00030 #include <kexidb/drivermanager.h>
00031 
00032 namespace Kross { namespace KexiDB {
00033 
00041     class KexiDBDriverManager : public Kross::Api::Class<KexiDBDriverManager>
00042     {
00043         protected:
00044 
00048             KexiDBDriverManager();
00049 
00053             virtual ~KexiDBDriverManager();
00054 
00055         public:
00056 
00060             static KexiDBDriverManager* self()
00061             {
00062                 static KexiDBDriverManager* manager = 0;
00063                 if(! manager)
00064                     manager = new KexiDBDriverManager();
00065                 return manager;
00066             }
00067 
00069             virtual const QString getClassName() const;
00070 
00071         private:
00072 
00082             inline ::KexiDB::DriverManager& driverManager();
00084             ::KexiDB::DriverManager m_drivermanager;
00085 
00091             Kross::Api::Object::Ptr driverNames(Kross::Api::List::Ptr);
00092 
00099             Kross::Api::Object::Ptr driver(Kross::Api::List::Ptr);
00100 
00107             Kross::Api::Object::Ptr lookupByMime(Kross::Api::List::Ptr);
00108 
00114             Kross::Api::Object::Ptr mimeForFile(Kross::Api::List::Ptr);
00115 
00119             Kross::Api::Object::Ptr createConnectionData(Kross::Api::List::Ptr);
00120 
00126             Kross::Api::Object::Ptr createConnectionDataByFile(Kross::Api::List::Ptr);
00127 
00131             Kross::Api::Object::Ptr field(Kross::Api::List::Ptr);
00132 
00136             Kross::Api::Object::Ptr tableSchema(Kross::Api::List::Ptr);
00137 
00141             Kross::Api::Object::Ptr querySchema(Kross::Api::List::Ptr);
00142     };
00143 
00144 }}
00145 
00146 #endif
00147 
KDE Home | KDE Accessibility Home | Description of Access Keys