SchedXactions* gnc_collection_get_schedxactions(const QofCollection *col) { SchedXactions *rtn = qof_collection_get_data(col); // @@assert(rtn != null); return rtn; }
/* Loop over every instance of the given type in the collection * of instances that we have on hand. */ static void qof_gobject_foreach (QofCollection *coll, QofInstanceForeachCB cb, gpointer ud) { GSList *n; n = qof_collection_get_data (coll); for (; n; n = n->next) { cb (n->data, ud); } }
static void book_sxes_end(QofBook* book) { QofCollection *col; SchedXactions *sxes; col = qof_book_get_collection(book, GNC_ID_SCHEDXACTION); sxes = qof_collection_get_data(col); if (sxes != NULL) { g_object_unref(sxes); qof_collection_set_data(col, NULL); } }
void qof_gobject_register_instance (QofBook *book, QofType type, GObject *gob) { QofCollection *coll; GSList *instance_list; if (!book || !type) return; coll = qof_book_get_collection (book, type); instance_list = qof_collection_get_data (coll); instance_list = g_slist_prepend (instance_list, gob); qof_collection_set_data (coll, instance_list); }
static Account * gnc_collection_get_template_root( const QofCollection *col ) { return qof_collection_get_data (col); }