qofquery-p.h

00001 /********************************************************************\
00002  * qofquery-p.h -- internal/private API for finding objects         *
00003  * Copyright (C) 2002 Derek Atkins <warlord@MIT.EDU>                *
00004  *                                                                  *
00005  * This program is free software; you can redistribute it and/or    *
00006  * modify it under the terms of the GNU General Public License as   *
00007  * published by the Free Software Foundation; either version 2 of   *
00008  * the License, or (at your option) any later version.              *
00009  *                                                                  *
00010  * This program is distributed in the hope that it will be useful,  *
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of   *
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the    *
00013  * GNU General Public License for more details.                     *
00014  *                                                                  *
00015  * You should have received a copy of the GNU General Public License*
00016  * along with this program; if not, contact:                        *
00017  *                                                                  *
00018  * Free Software Foundation           Voice:  +1-617-542-5942       *
00019  * 51 Franklin Street, Fifth Floor    Fax:    +1-617-542-2652       *
00020  * Boston, MA  02110-1301,  USA       gnu@gnu.org                   *
00021  *                                                                  *
00022 \********************************************************************/
00023 
00024 #ifndef QOF_QUERY_P_H
00025 #define QOF_QUERY_P_H
00026 
00027 #include "qofquery.h"
00028 
00029 typedef struct _QofQueryTerm QofQueryTerm;
00030 typedef struct _QofQuerySort QofQuerySort;
00031 
00032 /* Functions to get Query information */
00033 int qof_query_get_max_results (QofQuery *q);
00034 
00035 
00036 /* Functions to get and look at QueryTerms */
00037 
00038 /* This returns a List of List of Query Terms.  Each list of Query
00039  * Terms are ANDed together, and each list of ANDed terms are ORed
00040  * together.  So, what is returned is the 'or' list of 'and' lists
00041  * of query term objects.
00042  *
00043  * Note that you should NOT modify this list in any way.  It belongs
00044  * to the query.
00045  */
00046 GList * qof_query_get_terms (QofQuery *q);
00047 
00048 GSList * qof_query_term_get_param_path (QofQueryTerm *queryterm);
00049 QofQueryPredData *qof_query_term_get_pred_data (QofQueryTerm *queryterm);
00050 gboolean qof_query_term_is_inverted (QofQueryTerm *queryterm);
00051 
00052 
00053 /* Functions to get and look at QuerySorts */
00054 
00055 /* This function returns the primary, secondary, and tertiary sorts.
00056  * These are part of the query and should NOT be changed!
00057  */
00058 void qof_query_get_sorts (QofQuery *q, QofQuerySort **primary,
00059                        QofQuerySort **secondary, QofQuerySort **tertiary);
00060 
00061 GSList * qof_query_sort_get_param_path (QofQuerySort *querysort);
00062 gint qof_query_sort_get_sort_options (QofQuerySort *querysort);
00063 gboolean qof_query_sort_get_increasing (QofQuerySort *querysort);
00064 
00065 #endif /* QOF_QUERY_P_H */

Generated on Fri May 12 18:00:33 2006 for QOF by  doxygen 1.4.4