the init/.shutdown functions shouldn't be private

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@8808 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
Linas Vepstas 2003-06-30 05:59:14 +00:00
parent a59bc5a754
commit 55778231da
7 changed files with 40 additions and 32 deletions

View File

@ -280,7 +280,7 @@ qof_book_get_counter (QofBook *book, const char *counter_name)
return counter;
}
/* gncObject function implementation and registration */
/* QofObject function implementation and registration */
gboolean qof_book_register (void)
{
static QofQueryObject params[] = {

View File

@ -48,6 +48,9 @@ typedef struct _QofBook QofBook;
/** GList of QofBook */
typedef GList QofBookList;
/** Register the book boject with the QOF object system. */
gboolean qof_book_register (void);
/** Allocate, initialise and return a new QofBook. Books contain references
* to all of the top-level object containers. */
QofBook * qof_book_new (void);
@ -106,7 +109,7 @@ gint64 qof_book_get_counter (QofBook *book, const char *counter_name);
/** Book parameter names */
/**@{*/
#define QOF_BOOK_KVP "qof-kvp"
#define QOF_BOOK_KVP "qof-kvp"
/**@}*/

View File

@ -32,11 +32,6 @@
#include "qofbook.h"
#include "qofobject.h"
/* Initialize the object registration subsystem */
void qof_object_initialize (void);
void qof_object_shutdown (void);
/* Note that the following are per-class and not per-instance */
/* To be called from within the book */
void qof_object_book_begin (QofBook *book);
void qof_object_book_end (QofBook *book);

View File

@ -73,6 +73,13 @@ struct _QofObject {
};
/* -------------------------------------------------------------- */
/** Initialize the object registration subsystem */
void qof_object_initialize (void);
void qof_object_shutdown (void);
void qof_object_foreach_type (QofForeachTypeCB cb, gpointer user_data);
void qof_object_foreach (QofIdTypeConst type_name, QofBook *book,

View File

@ -29,10 +29,6 @@
typedef struct _QofQueryTerm QofQueryTerm;
typedef struct _QofQuerySort QofQuerySort;
/* Initialize/Shutdown */
void qof_query_init (void);
void qof_query_shutdown (void);
/* Functions to get Query information */
int qof_query_get_max_results (QofQuery *q);
@ -60,7 +56,7 @@ gboolean qof_query_term_is_inverted (QofQueryTerm *queryterm);
* These are part of the query and should NOT be changed!
*/
void qof_query_get_sorts (QofQuery *q, QofQuerySort **primary,
QofQuerySort **secondary, QofQuerySort **tertiary);
QofQuerySort **secondary, QofQuerySort **tertiary);
GSList * qof_query_sort_get_param_path (QofQuerySort *querysort);
gint qof_query_sort_get_sort_options (QofQuerySort *querysort);

View File

@ -49,14 +49,21 @@ typedef enum {
#define QOF_QUERY_FIRST_TERM QOF_QUERY_AND
/** Default sort object type */
#define QUERY_DEFAULT_SORT "GnucashQueryDefaultSortObject"
#define QUERY_DEFAULT_SORT "QofQueryDefaultSort"
/** "Known" Object Parameters -- all objects must support these */
#define QOF_QUERY_PARAM_BOOK "book"
#define QOF_QUERY_PARAM_GUID "guid"
#define QOF_QUERY_PARAM_ACTIVE "active" /* it's ok if an object does
* not support this */
#define QOF_QUERY_PARAM_BOOK "book"
#define QOF_QUERY_PARAM_GUID "guid"
#define QOF_QUERY_PARAM_ACTIVE "active" /* it's ok if an object does
* not support this */
/* --------------------------------------------------------- */
/** Startup and Shutdown */
void qof_query_init (void);
void qof_query_shutdown (void);
/* --------------------------------------------------------- */
/** Basic API Functions */
GSList * qof_query_build_param_list (char const *param, ...);
@ -87,23 +94,23 @@ void qof_query_set_book (QofQuery *q, QofBook *book);
* For example:
*
* acct_name_pred_data = make_string_pred_data(QOF_STRING_MATCH_CASEINSENSITIVE,
* account_name);
* account_name);
* param_list = make_list (SPLIT_ACCOUNT, ACCOUNT_NAME, NULL);
* qof_query_add_term (query, param_list, QOF_COMPARE_EQUAL,
* acct_name_pred_data, QOF_QUERY_AND);
* acct_name_pred_data, QOF_QUERY_AND);
*/
void qof_query_add_term (QofQuery *query, GSList *param_list,
QofQueryPredData *pred_data, QofQueryOp op);
QofQueryPredData *pred_data, QofQueryOp op);
void qof_query_add_guid_match (QofQuery *q, GSList *param_list,
const GUID *guid, QofQueryOp op);
const GUID *guid, QofQueryOp op);
void qof_query_add_guid_list_match (QofQuery *q, GSList *param_list,
GList *guid_list, QofGuidMatch options,
QofQueryOp op);
GList *guid_list, QofGuidMatch options,
QofQueryOp op);
void qof_query_add_boolean_match (QofQuery *q, GSList *param_list, gboolean value,
QofQueryOp op);
QofQueryOp op);
/** Run the query: */
GList * qof_query_run (QofQuery *query);
@ -138,15 +145,15 @@ void qof_query_merge_in_place(QofQuery *q1, QofQuery *q2, QofQueryOp op);
* by the query when it is destroyed.
*/
void qof_query_set_sort_order (QofQuery *q,
GSList *primary_sort_params,
GSList *secondary_sort_params,
GSList *tertiary_sort_params);
GSList *primary_sort_params,
GSList *secondary_sort_params,
GSList *tertiary_sort_params);
void qof_query_set_sort_options (QofQuery *q, gint prim_op, gint sec_op,
gint tert_op);
gint tert_op);
void qof_query_set_sort_increasing (QofQuery *q, gboolean prim_inc,
gboolean sec_inc, gboolean tert_inc);
gboolean sec_inc, gboolean tert_inc);
void qof_query_set_max_results (QofQuery *q, int n);

View File

@ -243,10 +243,10 @@ foreach (@files)
s/getDateFormat/qof_date_format_get/g;
s/setDateFormat/qof_date_format_set/g;
s/DateFormat/QofDateFormat/g;
s/printDateSecs/qof_print_date_secs_buff/g;
s/printDate/qof_print_date_buff/g;
s/printDateSecs/qof_print_date_buff/g;
s/printDate/qof_print_date_dmy_buff/g;
s/printGDate/qof_print_gdate/g;
s/xaccPrintDateSecs/qof_print_date_secs/g;
s/xaccPrintDateSecs/qof_print_date/g;
s/scanDate/qof_scan_date/g;
s/DATE_FORMAT_US/QOF_DATE_FORMAT_US/g;
s/DATE_FORMAT_UK/QOF_DATE_FORMAT_UK/g;