Main Page | Namespace List | Class Hierarchy | Class List | File List | Class Members | File Members | Related Pages

hk_drivermanager Class Reference

Database Driver administration. More...

#include <hk_drivermanager.h>

Inheritance diagram for hk_drivermanager:

hk_class List of all members.

Public Member Functions

 hk_drivermanager (void)
 hk_drivermanager (bool runtime)
virtual ~hk_drivermanager (void)
hk_connectionnew_connection (const hk_string &drivername="", enum_interaction i=interactive)
hk_connectionfind_existing_connection (const hk_string &drivername, const hk_string &host, unsigned int tcp_port, const hk_string &user)
hk_databaseopen_connectionfile (const hk_url &connectionfile)

Static Public Member Functions

static vector< hk_string > * driverlist (void)
static void set_path (const hk_string &path)
static hk_string path (void)
static void set_driverselectdialog (requestdialogtype *dialog)
static hk_string show_driverselectdialog (void)

Friends

class hk_connection

Detailed Description

Database Driver administration.

Version:
Revision
1.22
Author:
Horst Knorr (hk_classes@knoda.org)
This class allows you to handle the database drivers. You can get a new connection to a database with new_connection.


Constructor & Destructor Documentation

hk_drivermanager::hk_drivermanager void   ) 
 

Parameters:
runtime if true the user has no possibility to change table and form structures or query statements

hk_drivermanager::hk_drivermanager bool  runtime  ) 
 

virtual hk_drivermanager::~hk_drivermanager void   )  [virtual]
 


Member Function Documentation

static vector<hk_string>* hk_drivermanager::driverlist void   )  [static]
 

hk_connection* hk_drivermanager::find_existing_connection const hk_string drivername,
const hk_string host,
unsigned int  tcp_port,
const hk_string user
 

If an already created connection exists, it will be returned otherwise NULL

hk_connection* hk_drivermanager::new_connection const hk_string drivername = "",
enum_interaction  i = interactive
 

with this method you can create a new connection to a database. If no driver is set a dialog appears which asks for the driver. You can set a GUI dependend driverdialog with set_driverselectdialog.

Parameters:
drivername name of the wished database driver (i.e. mysql)
i if i is set to 'interactive' warningmessages and dialog boxes will be shown
Returns:
a driver specific version of hk_connection or NULL if no driver could be found.

hk_database* hk_drivermanager::open_connectionfile const hk_url &  connectionfile  ) 
 

static hk_string hk_drivermanager::path void   )  [static]
 

static void hk_drivermanager::set_driverselectdialog requestdialogtype *  dialog  )  [static]
 

you can write your own GUI dependend function to show a driver select dialog by defining a function of requestdialogtype

static void hk_drivermanager::set_path const hk_string path  )  [static]
 

Path to the directory where the database drivers are stored.(default: /usr/lib/hk_classes/drivers)

static hk_string hk_drivermanager::show_driverselectdialog void   )  [static]
 


Friends And Related Function Documentation

friend class hk_connection [friend]
 


The documentation for this class was generated from the following file:
Generated on Thu Mar 9 18:40:41 2006 for hk_classes by  doxygen 1.4.1