dear lazyweb: please name DValue

DValue is the datatype at the foundation of dconf and of the glib-based dbus bindings that rob and ori are theoretically working on. it will end up being part of libglib (probably for the release before next guadec).

it is named DValue because it used to be named DConfValue.

you can read a little bit about DValue here.

one thing to note is that, unlike GValue, a DValue is actually a value — not a container or a variable. it can only exist as a value with a type and the value can never change. when you create it it has a value and the only way to get rid of that value is to destroy it. also note that it can contain exactly those values that can be sent over dbus. it cannot contain, for example, object references.

the problem is that its name starts with a ‘d’ and everything in glib must start with ‘g’. i would rename it to GValue but i cannot do this for obvious reasons.

i need a name for it that starts with g. this is something that a lot of people have thought about for a long time without coming up with any good name.

all suggestions must start with G, be short (G + 5 chars max) and not conflict with anything currently in glib or gobject. entries will be judged by my personal whim. i will buy the winner a cookie at our next meeting. feel free to list many suggestions but note that most of the obvious ones have already been considered and shot down for some reason or another…

thanks :)

21 thoughts on “dear lazyweb: please name DValue”

  1. GBag
    GBase
    GBin
    GBox
    GCapsule
    GCompact
    GContainer
    GHolder
    GPack
    GPurse
    GSack

    or maybe just go with the obvious synonym for value: GProfit

  2. GAtom
    GLuon | gluon (we’ve already got GQuarks, why not?)
    GMorph
    GPart
    GPrim
    GThing
    GThang (Berkeley DB uses DBTs which stand for Database thangs–they were faced with the same problem and never though of anything better)

  3. The way you describe this type, it gets a value when you construct it, and never changes value. I would name it based on that property:

    GConst (pairs nicely with GValue)
    GImmut
    GFinal
    GPure
    GRVal (as in “R-value”)
    GBind
    GBound (though that sounds too much like the “bounds” of a range rather than a binding to a value)

    Alternatively, based on its use as a wrapped DBus value:

    GParam
    GArg
    GWrap
    GWrapd
    GDBus

    Alternatively, based on your description of the types of values it can hold:

    GPOD (“plain old data”)
    GPODT

  4. GCopy (which has the advantage of reminding people that it represents a copy when you pass it around, not a reference)

  5. This might sound stupid, but why cann’t you just use/extend GValue? From the docs you linked there seems to be quite some overlap between GValue and DValue.

  6. Immutable value of any type? Such thing is named a constant, so GConst. Maybe GAtom if some other language calls it so?..

  7. I’m voting for GConst, or at the extreme, GConstValue, as it even more clearly illustrates what it is.

    GAtom wouldn’t be bad except we already have GQuark and well, I think the physics guys would start throwing things at us.

  8. genue or genvue, short for “Gnome GENeric ValUE datatype”.

    genue has, as a benefit, a geek connotation. According to Wookieepedia, Genue was a BFF-1 bulk freighter used by the Galactic Empire during the Galactic Civil War.

Comments are closed.