Re: [gnome-db] Delete GdaValue and use only GValue proporsal





2006/3/21, Vivien Malerba <vmalerba gmail com>:
On 3/20/06, Daniel Espinosa <esodan gmail com> wrote:
> As I know, most of the new or actual users of the libgda, may don't know
> about GdaValue is now realy GValue, and that's why may mos of them don't use
> the GLib's related functions about it; for this reazon I propose to delete
> the GdaValue as a Type and use, for all the API and providers developtment,
> GValue enstead.

The GdaValue is indeed defined as a GValue, but it has the following advantages:
-> there is only a limited number of value types which the providers
are supposed to handle, which means data handling is easier to write
since the types to handle are known.

This could remain, GdaValue use the existing types in GLib and defind the new it uses; then new types and may be the re-difined ones could remain. Just only if we could use directly the GLib type to avoid incorrect use or interpretation of the type: for example SINGLE is not too clear that means FLOAT.

-> each value type is part of an enum which means it can be used in
switch statements

In my work to port to GValue I evaluate to delete the enumeration, but needs to change a lot of code; then I think this could remain, but may be is a good idea to reimplement the code to avoid this.
 

-> there is the NULL GdaValue which is different than the NULL pointer
and which is not handled this way in GValues.

GValue can use the NULL type too; just an uninitated GValue is a NULL one.
 

Considering the points mentionned above, I don't see what the point of
removing the GdaValue is.


I think, that most of the the types definition, enums, and other thinks that help in GDA must remain; the point is for example delete the gda_value_new_* functions and other stuff that has a contrapart in GLib, to allow the developer to shoose one function in GLib and know, at the first step, that GDA use GValue as the values manipulation.



--
Trabajar, la mejor arma para tu superación
"de grano en grano, se hace la arena" (R) (entrámite, pero para los cuates: LIBRE)

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]