Loading...
Searching...
No Matches
comps_doccategory.h
Go to the documentation of this file.
/* libcomps - C alternative to yum.comps library
* Copyright (C) 2013 Jindrich Luza
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
* USA
*/
#ifndef COMPS_DOCCATEGORY_H
#define COMPS_DOCCATEGORY_H
#include "comps_obj.h"
#include "comps_objdict.h"
#include "comps_objlist.h"
#include "comps_utils.h"
#include "comps_docgroupid.h"
#include "comps_validate.h"
#include "comps_radix.h"
#include "comps_log.h"
#include "comps_default.h"
#include <stddef.h>
#include <assert.h>
typedef struct {
COMPS_Object_HEAD;
COMPS_ObjDict *properties;
COMPS_ObjDict *name_by_lang;
COMPS_ObjDict *desc_by_lang;
COMPS_ObjList *group_ids;
} COMPS_DocCategory;
COMPS_Object_TAIL(COMPS_DocCategory);
//HEAD_COMPS_CREATE_u(doccategory, COMPS_DocCategory) /*comps_utils.h macro*/
//HEAD_COMPS_COPY_u(doccategory, COMPS_DocCategory) /*comps_utils.h macro*/
//HEAD_COMPS_DESTROY_u(doccategory, COMPS_DocCategory) /*comps_utils.h macro*/
HEAD_COMPS_STRPROP_SETTER(category, COMPS_DocCategory, id) /*comps_utils.h macro*/
HEAD_COMPS_STRPROP_SETTER(category, COMPS_DocCategory, name) /*comps_utils.h macro*/
HEAD_COMPS_STRPROP_SETTER(category, COMPS_DocCategory, desc) /*comps_utils.h macro*/
HEAD_COMPS_NUMPROP_SETTER(category, COMPS_DocCategory,
display_order) /*comps_utils.h macro*/
HEAD_COMPS_PROP_GETTER(category, COMPS_DocCategory, id) /*comps_utils.h macro*/
HEAD_COMPS_PROP_GETTER_OBJ(category, id) /*comps_utils.h macro*/
HEAD_COMPS_PROP_GETTER(category, COMPS_DocCategory, name) /*comps_utils.h macro*/
HEAD_COMPS_PROP_GETTER(category, COMPS_DocCategory, desc) /*comps_utils.h macro*/
HEAD_COMPS_PROP_GETTER(category, COMPS_DocCategory, display_order) /*comps_utils.h macro*/
HEAD_COMPS_DOCOBJ_GETOBJLIST(doccategory, COMPS_DocCategory, group_ids, group_ids)
HEAD_COMPS_DOCOBJ_SETOBJLIST(doccategory, COMPS_DocCategory, group_ids, group_ids)
HEAD_COMPS_DOCOBJ_GETARCHES(doccategory, COMPS_DocCategory)
HEAD_COMPS_DOCOBJ_SETARCHES(doccategory, COMPS_DocCategory)
char __comps_doccategory_idcmp(void *c1, void *c2);
signed char comps_doccategory_cmp_u(COMPS_Object *cat1, COMPS_Object *cat2);
void comps_doccategory_add_groupid(COMPS_DocCategory *cat,
COMPS_DocGroupId *gid);
COMPS_DocCategory* comps_doccategory_union(COMPS_DocCategory *c1,
COMPS_DocCategory *c2);
COMPS_DocCategory* comps_doccategory_intersect(COMPS_DocCategory *c1,
COMPS_DocCategory *c2);
signed char comps_doccategory_xml(COMPS_DocCategory *category,
xmlTextWriterPtr writer, COMPS_Log *log,
COMPS_XMLOptions *xml_options,
COMPS_DefaultsOptions *def_options);
COMPS_DocCategory* comps_doccategory_arch_filter(COMPS_DocCategory *source,
COMPS_ObjList *arches);
extern COMPS_ValRuleGeneric* COMPS_DocCategory_ValidateRules[];
#endif
comps_doccategory_add_groupid
void comps_doccategory_add_groupid(COMPS_DocCategory *cat, COMPS_DocGroupId *gid)
comps_doccategory_cmp_u
signed char comps_doccategory_cmp_u(COMPS_Object *cat1, COMPS_Object *cat2)
comps_doccategory_union
COMPS_DocCategory * comps_doccategory_union(COMPS_DocCategory *c1, COMPS_DocCategory *c2)
comps_doccategory_intersect
COMPS_DocCategory * comps_doccategory_intersect(COMPS_DocCategory *c1, COMPS_DocCategory *c2)
comps_docgroupid.h
COMPS_DocGroupId header file.
comps_obj.h
COMPS_Object header file.
COMPS_Object_HEAD
#define COMPS_Object_HEAD
Definition comps_obj.h:86
COMPS_Object_TAIL
#define COMPS_Object_TAIL(obj)
insert "extern COMPS_ObjectInfo <obj>_ObjInfo" statement. Use this macro in combination with COMPS_OB...
Definition comps_obj.h:89
comps_objdict.h
Libcomps dictionary and multi-dictionary. COMPS_ObjDict and COMPS_ObjMDict are both derivates of COMP...
comps_objlist.h
A Documented file. Details.
COMPS_DocCategory
Definition comps_doccategory.h:49
COMPS_DocCategory::properties
COMPS_ObjDict * properties
Definition comps_doccategory.h:51
COMPS_DocCategory::name_by_lang
COMPS_ObjDict * name_by_lang
Definition comps_doccategory.h:52
COMPS_DocCategory::desc_by_lang
COMPS_ObjDict * desc_by_lang
Definition comps_doccategory.h:53
COMPS_DocCategory::group_ids
COMPS_ObjList * group_ids
Definition comps_doccategory.h:55
COMPS_DocGroupId
Definition comps_docgroupid.h:36
COMPS_ObjList
Definition comps_objlist.h:41
COMPS_Object
Definition comps_obj.h:124