[Gambas-user] Fwd: Database Component Development Discussion

Benoît Minisini gambas at ...1...
Sat Nov 16 12:26:38 CET 2002


Subject: Database Component Development Discussion
Date: Thu, 14 Nov 2002 10:49:04 -0000
From: "Nigel GERRARD" <nigel at ...38...>

In a recent email exchange with Benoît concerning the creation of a new
 database component for gambas,  Benoît expressed a wish to discuss details
 on design within the mailing list. He states:

'We must design a good and solid object model for the database component
 before going too far (Note: I had started creating a component based solely
 on QT).  I have the same worries that I had with the QT component : the
 database component must not have an interface tied to a particular library,
 so that anyone can offer a database component based on a library different
 than QT.'

Further, Benoît goes on to say:

'For a database component, I suggest you to create a main database component
 that contain all the classes, and many other little components with no
 classes, one for each database type, that communicate with the main database
 component by an interface. These little components could be loaded by demand
 (I must add a function for that in the Gambas API). What do you think about
 that ?'

My understanding from this would be that the main database component would be
 written with no dependencies on libraries; it would contain all the methods 
 and properties that would need to be implemented within the 'little'
 components.  So in the 'Database' component we might hold properties for
 Databasename, Username, Password, Port number, Driver (Postgresql/Mysql
 etc.) and methods such as Open and Close.  The methods would then call the
 relevant function from the sub-component (written with library
 dependencies..unless we are going to be clever and re-invent the wheel)

...okay, so it's a little vague at the moment...but we have an opportunity
 here to define the way it will work :-)

I believe we need to design?:

What/How the interface will work
What Properties are required
What Methods will be needed

Now let battle commence.......

Nigel





More information about the User mailing list