RE: [gnome-db]Re: Anderson Clayton's helping demand
- From: Rodrigo Moya <rodrigo gnome-db org>
- To: Laurent Marzullo <laurent marzullo be sema com>
- Cc: Gnome DB <gnome-db-list gnome org>
- Subject: RE: [gnome-db]Re: Anderson Clayton's helping demand
- Date: 23 Jan 2001 16:41:03 +0100
On 22 Jan 2001 10:25:31 +0100, Laurent Marzullo wrote:
> > Hi!
> >
> >
> > Well, as far as I've seen, your bindings are not correct. I don't mean
> > that they're bad, but they've got some "problems":
> > * you're using OAF/GConf directly: don't do this please. The reason for
> > the existance of the libgda-common is to serve as a wrapper for all
> > those things, to allow porting everything to another system by just
> > changing that library. What the C++ bindings must do is to use directly
> > the functions in the libgda-common library/libgda-client, etc
>
> Yes I know. But as I said, my philosophy is to write a real C++ code.
> So, I make a wrapper for GConf and one for CORBA (Which is not really
> a wrapper but just a class and some function to use them in a C++ way)
> So, use libgda function is not possible in this philosophy.
>
> I know that this philosphy will bring to make up change in two sources
> instead of only one. But the problem is how to do a wrapper ?
yes, that's the main problem. We'll have to maintan repeated code.
About how to make a wrapper, I think it's quite easy. You are free to
implement the C++ code as you wish, but any time you have to use
GConf/OAF/CORBA, etc, you use the libgda-* exported interface.
For example, the App class you added is ok, you could add there methods
for getting the list of providers, DSN, and to the configuration file.
CORBA stuff should only be used inside the C++ bindings, and not by apps
using them.
> What I mean is:
> 1 May we do a wrapper for only libgda-server & libgda-client using
> libgda-common C library (and not a libgda-common C++ lib)
>
> 2 May we do a wrapper for all 3 libraries and use libgda-common
> function for GConf and CORBA.
>
> 3 May we do a wrapper for all 3 lib and for GConf & CORBA.
> (Wrapper for GConf & CORBA could be seen as a separate
> project ...)
>
> For me, 2 is the best one, because for (3) perhaps it will be more
> suitable to see wrapper for GConf & CORBA as separate project which
> will not be part of libgdamm.
>
well, that's another story. But anyway, even if we have good C++
bindings for GConf and CORBA, you should still be using the gda-common
lib for all those things, so that, as I said before, the only
platform-specific code is in only one place (libgda-common).
> > * namespace: you're using an ambigous namespace for all your files. You
> > should name them in a form similar to the rest (gda-client.h,
> > gda-common.h, etc). What about CGdaConnection.h, CGdaCommon.h? or
> > whatever you prefer, but use something to uniquely identify your header
> > files.
>
> ok, first you speak about file name and not namespace :-)
yes, sorry, I meant file names
> There's no problem to me to change file name. My preference goes
> to name file with Cap like GDACommon.h, GDAServer.h etc, but to
> be in harmony with libgda & gnome-db file name perhaps shouldn't we
> use Cap in file name ? I don't really know what is prefereable for
> file name.
>
> but GDACommon.h GDAProvider.h GDAApp.h GDADSN.h it's ok.
>
whatever you prefer.
cheers
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]