/builddir/build/BUILD/libcomps-libcomps-0.1.8/libcomps/src/comps_doc.h File Reference

COMPS_Doc header file. More...

#include "comps_obj.h"
#include "comps_objdict.h"
#include "comps_objlist.h"
#include "comps_log.h"
#include "comps_types.h"
#include "comps_docgroup.h"
#include "comps_doccategory.h"
#include "comps_docenv.h"
#include "comps_validate.h"
#include "comps_default.h"

Go to the source code of this file.

Data Structures

struct  COMPS_Doc

Functions

void comps_doc_create (COMPS_Doc *doc, COMPS_Object **args)
void comps_doc_copy (COMPS_Doc *doc_dst, COMPS_Doc *doc_src)
void comps_doc_destroy (COMPS_Doc *doc)
signed char comps_doc_cmp_u (COMPS_Object *obj1, COMPS_Object *obj2)
COMPS_ObjListCONCAT (comps_doc_, groups)(COMPS_Doc *doc)
COMPS_ObjListCONCAT (comps_doc_, categories)(COMPS_Doc *doc)
COMPS_ObjListCONCAT (comps_doc_, environments)(COMPS_Doc *doc)
COMPS_ObjDict * CONCAT (comps_doc_, langpacks)(COMPS_Doc *doc)
COMPS_ObjMDict * CONCAT (comps_doc_, blacklist)(COMPS_Doc *doc)
COMPS_ObjMDict * CONCAT (comps_doc_, whiteout)(COMPS_Doc *doc)
void CONCAT (comps_doc_set_, groups)(COMPS_Doc *doc
void CONCAT (comps_doc_set_, categories)(COMPS_Doc *doc
void CONCAT (comps_doc_set_, environments)(COMPS_Doc *doc
void CONCAT (comps_doc_set_, langpacks)(COMPS_Doc *doc
void CONCAT (comps_doc_set_, blacklist)(COMPS_Doc *doc
void CONCAT (comps_doc_set_, whiteout)(COMPS_Doc *doc
void CONCAT (comps_doc_add_, group)(COMPS_Doc *doc
void CONCAT (comps_doc_add_, category)(COMPS_Doc *doc
void CONCAT (comps_doc_add_, environment)(COMPS_Doc *doc
void CONCAT (comps_doc_add_, langpack)(COMPS_Doc *doc
void CONCAT (comps_doc_add_, blacklist)(COMPS_Doc *doc
void CONCAT (comps_doc_add_, whiteout)(COMPS_Doc *doc
void CONCAT (comps_doc_set_, lang)(COMPS_Doc *doc
signed char comps2xml_f (COMPS_Doc *doc, char *filename, char stdoutredirect, COMPS_XMLOptions *xml_options, COMPS_DefaultsOptions *def_options)
char * comps2xml_str (COMPS_Doc *doc, COMPS_XMLOptions *options, COMPS_DefaultsOptions *def_options)
COMPS_Doccomps_doc_union (COMPS_Doc *c1, COMPS_Doc *c2)

Detailed Description

COMPS_Doc header file.

COMPS_Doc object support union operation. Read more about Libcomps objects unioning

See also:
COMPS_Doc getters
COMPS_Doc setters
COMPS_Doc adders

Function Documentation

signed char comps2xml_f ( COMPS_Doc doc,
char *  filename,
char  stdoutredirect,
COMPS_XMLOptions *  xml_options,
COMPS_DefaultsOptions *  def_options 
)

Write XML representation to file

Parameters:
doc COMPS_Doc object
filename filename where to write
stdoutredirect in non-zero all warning and error messages will be redirected to stdout, otherwise will be stored in doc->log only
Returns:
0 if there wasn't any errors, 1 if there was non-fatal errors -1 if fatal error emerge during xml generation
char* comps2xml_str ( COMPS_Doc doc,
COMPS_XMLOptions *  options,
COMPS_DefaultsOptions *  def_options 
)

Generate XML string representating COMPS_Doc structure

Parameters:
doc COMPS_Doc object
Returns:
XML string
signed char comps_doc_cmp_u ( COMPS_Object obj1,
COMPS_Object obj2 
)

comparator callback for COMPS_Doc object

void comps_doc_copy ( COMPS_Doc doc_dst,
COMPS_Doc doc_src 
)

copy callback for COMPS_Doc object

void comps_doc_create ( COMPS_Doc doc,
COMPS_Object **  args 
)

constructor callback for COMPS_Doc object. COMPS_Doc is COMPS_Object derivate. Use comps_object_create() or COMPS_OBJECT_CREATE for construction instead

Parameters:
doc allocated COMPS_Doc object
args array of constructor arguments. COMPS_Doc constructor accepts encoding argument as COMPS_Str object only so array need not end with sentinel item
void comps_doc_destroy ( COMPS_Doc doc  ) 

destructor callback for COMPS_Doc object. COMPS_Doc is COMPS_Object derivate. Use comps_object_create() for construction instead

COMPS_Doc* comps_doc_union ( COMPS_Doc c1,
COMPS_Doc c2 
)

Union two COMPS_Doc structures COMPS_Doc structures are unioned as unioning it's subparts (group, categories, environments). Object with same 'id' attribute are regarded as equal and unioned by with each other

Parameters:
c1 COMPS_Doc object
c2 COMPS_Doc object
 All Data Structures Files Functions Variables Enumerations Defines

Generated on 1 Mar 2019 for libcomps by  doxygen 1.6.1