cpedict_priv.h
Go to the documentation of this file.
/*
* Copyright 2009 Red Hat Inc., Durham, North Carolina.
* All Rights Reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library 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
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
* Authors:
* Maros Barabas <mbarabas@redhat.com>
*/
#ifndef CPEDICT_PRIV_H_
#define CPEDICT_PRIV_H_
#include <libxml/xmlreader.h>
#include <libxml/xmlwriter.h>
#include <stdlib.h>
#include "cpe_name.h"
#include "cpe_ctx_priv.h"
#include "../common/public/oscap.h"
#include "../common/util.h"
#include "../common/elements.h"
OSCAP_HIDDEN_START;
/* @endcond */
struct cpe_check;
struct cpe_reference;
struct cpe_item;
struct cpe_dict_model;
struct cpe_item_metadata;
struct cpe_generator;
struct cpe_vendor;
struct cpe_product;
struct cpe_version;
struct cpe_update;
struct cpe_edition;
struct cpe_language;
struct cpe_dict_model *cpe_dict_model_parse_xml(const char *file);
struct cpe_generator *cpe_generator_parse(struct cpe_parser_ctx *ctx);
struct cpe_item *cpe_item_parse(struct cpe_parser_ctx *ctx);
struct cpe_vendor *cpe_vendor_parse(xmlTextReaderPtr reader);
struct cpe_dict_model *cpe_dict_model_parse(struct cpe_parser_ctx *ctx);
void cpe_dict_model_export_xml(const struct cpe_dict_model *dict, const char *file);
void cpe_dict_export(const struct cpe_dict_model *dict, xmlTextWriterPtr writer);
void cpe_generator_export(const struct cpe_generator *generator, xmlTextWriterPtr writer);
void cpe_item_export(const struct cpe_item *item, xmlTextWriterPtr writer, int base_version);
void cpe_vendor_export(const struct cpe_vendor *vendor, xmlTextWriterPtr writer);
/* <cpe-list>
* */
struct cpe_dict_model { // the main node
struct oscap_list *items; // dictionary items
struct oscap_list *vendors;
int base_version;
struct cpe_generator *generator;
char* origin_file;
};
OSCAP_HIDDEN_END;
/* @endcond */
#endif