QofSetterFunc
Linas Vepstas
linas at linas.org
Sat Jul 24 19:23:50 EDT 2004
On Sat, Jul 24, 2004 at 07:48:57PM +0100, Neil Williams was heard to remark:
> I see that most qof_class_register calls set a NULL in place of the possible
> QofSetterFunc. I couldn't find a single (QofSetterFunc) with a grep of src/
> but maybe that's just me.
:) its a place holder, haven't gotten around to filling it in.
The setters are used in qof and I think in gnotime.
> I've got my own code to work when e.g. Account.c has a corresponding
> QofSetterFunc defined:
> { ACCOUNT_NAME_, QOF_TYPE_STRING, (QofAccessFunc)xaccAccountGetName,
> (QofSetterFunc) xaccAccountSetName },
Yep, that's the idea.
> Was it an oversight not to specify QofSetterFunc's?
No.
> Or just that nobody had a
> use for them, yet?
Yes.
> Can I change each qof_class_register section to use appropriate Set functions,
> where they exist?
Yes.
> (If they don't, I'll cross that bridge when I get to it!)
Heh.
I've converted most things to use QofEntity; I was planing on converting
most things to actually use QofInstance (so that they would all have a
common setter for the KVP tree, and some other common items.) Prices
stick out like a sore thumb, and would need a major overhaul. There
are other odds-n-ends, such as currencies.
I was planning on adding reference counting to QofInstance. ...
I was planing on changing gnc-event to send out references to entities
and not to guids ....
Since my whiz-bang SQL backend requires the setters, I was holding off
till then ...
--linas
--
pub 1024D/01045933 2001-02-01 Linas Vepstas (Labas!) <linas at linas.org>
PGP Key fingerprint = 8305 2521 6000 0B5E 8984 3F54 64A9 9A82 0104 5933
More information about the gnucash-devel
mailing list