QOF: qofchoice.h Source File

QOF 0.7.5

qofchoice.h
Go to the documentation of this file.
1 /***************************************************************************
2 * qofchoice.h
3 *
4 * Thu Jul 7 12:25:24 2005
5 * Copyright 2005 Neil Williams
6 * linux@codehelp.co.uk
7 ****************************************************************************/
8 /*
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2 of the License, or
12 * (at your option) any later version.
13 *
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
18 *
19 * You should have received a copy of the GNU General Public License
20 * along with this program; if not, write to the Free Software
21 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
22 */
23
24 #ifndef _QOFCHOICE_H
25 #define _QOFCHOICE_H
26
93 #include "qofclass.h"
94 #include "qofobject.h"
95
96 #define QOF_MOD_CHOICE "qof-choice"
97
103 #define QOF_TYPE_CHOICE "choice"
104
116 gboolean qof_object_is_choice (QofIdType type);
117
119 gboolean qof_choice_create (gchar *type);
120
130 gboolean
131 qof_choice_add_class (gchar *choice, gchar *add, gchar *param_name);
132
143 GList *qof_object_get_choices (QofIdType type, QofParam * param);
144
154 gboolean
155 qof_choice_check (gchar *choice_obj, gchar *param_name, gchar *choice);
159 #endif /* _QOFCHOICE_H */
QofIdType
const gchar * QofIdType
Definition: qofid.h:81
_QofParam
Definition: qofclass.h:195
qofobject.h
the Core Object Description Interface
qof_choice_create
gboolean qof_choice_create(gchar *type)
Set an object as using QOF_TYPE_CHOICE.
Definition: qofchoice.c:61
qofclass.h
API for registering paramters on objects.
qof_object_get_choices
GList * qof_object_get_choices(QofIdType type, QofParam *param)
Return the list of all object types usable with this parameter.
Definition: qofchoice.c:94
qof_object_is_choice
gboolean qof_object_is_choice(QofIdType type)
Does this object contain a choice parameter?
Definition: qofchoice.c:45
qof_choice_add_class
gboolean qof_choice_add_class(gchar *choice, gchar *add, gchar *param_name)
Add the choices for this parameter to the object.
Definition: qofchoice.c:75
qof_choice_check
gboolean qof_choice_check(gchar *choice_obj, gchar *param_name, gchar *choice)
Is the choice valid for this param_name?
Definition: qofchoice.c:108