|
Packit Service |
ea0369 |
/*
|
|
Packit Service |
ea0369 |
* libvirt-gconfig-helpers-private.h: libvirt configuration helpers
|
|
Packit Service |
ea0369 |
*
|
|
Packit Service |
ea0369 |
* Copyright (C) 2010, 2011 Red Hat, Inc.
|
|
Packit Service |
ea0369 |
*
|
|
Packit Service |
ea0369 |
* This library is free software; you can redistribute it and/or
|
|
Packit Service |
ea0369 |
* modify it under the terms of the GNU Lesser General Public
|
|
Packit Service |
ea0369 |
* License as published by the Free Software Foundation; either
|
|
Packit Service |
ea0369 |
* version 2.1 of the License, or (at your option) any later version.
|
|
Packit Service |
ea0369 |
*
|
|
Packit Service |
ea0369 |
* This library is distributed in the hope that it will be useful,
|
|
Packit Service |
ea0369 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
Packit Service |
ea0369 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
Packit Service |
ea0369 |
* Lesser General Public License for more details.
|
|
Packit Service |
ea0369 |
*
|
|
Packit Service |
ea0369 |
* You should have received a copy of the GNU Lesser General Public
|
|
Packit Service |
ea0369 |
* License along with this library. If not, see
|
|
Packit Service |
ea0369 |
* <http://www.gnu.org/licenses/>.
|
|
Packit Service |
ea0369 |
*
|
|
Packit Service |
ea0369 |
* Authors: Daniel P. Berrange <berrange@redhat.com>
|
|
Packit Service |
ea0369 |
* Christophe Fergeau <cfergeau@gmail.com>
|
|
Packit Service |
ea0369 |
*/
|
|
Packit Service |
ea0369 |
|
|
Packit Service |
ea0369 |
#if !defined(__LIBVIRT_GCONFIG_H__) && !defined(LIBVIRT_GCONFIG_BUILD)
|
|
Packit Service |
ea0369 |
#error "Only <libvirt-gconfig/libvirt-gconfig.h> can be included directly."
|
|
Packit Service |
ea0369 |
#endif
|
|
Packit Service |
ea0369 |
|
|
Packit Service |
ea0369 |
#ifndef __LIBVIRT_GCONFIG_HELPERS_PRIVATE_H__
|
|
Packit Service |
ea0369 |
#define __LIBVIRT_GCONFIG_HELPERS_PRIVATE_H__
|
|
Packit Service |
ea0369 |
|
|
Packit Service |
ea0369 |
G_BEGIN_DECLS
|
|
Packit Service |
ea0369 |
|
|
Packit Service |
ea0369 |
GError *gvir_config_error_new(GQuark domain, gint code,
|
|
Packit Service |
ea0369 |
const gchar *format, ...)
|
|
Packit Service |
ea0369 |
G_GNUC_PRINTF(3, 4);
|
|
Packit Service |
ea0369 |
void gvir_config_set_error(GError **err,
|
|
Packit Service |
ea0369 |
GQuark domain, gint code,
|
|
Packit Service |
ea0369 |
const gchar *format, ...)
|
|
Packit Service |
ea0369 |
G_GNUC_PRINTF(4, 5);
|
|
Packit Service |
ea0369 |
void gvir_config_set_error_literal(GError **err,
|
|
Packit Service |
ea0369 |
GQuark domain, gint code,
|
|
Packit Service |
ea0369 |
const gchar *message);
|
|
Packit Service |
ea0369 |
void gvir_config_set_error_valist(GError **err,
|
|
Packit Service |
ea0369 |
GQuark domain, gint code,
|
|
Packit Service |
ea0369 |
const gchar *format,
|
|
Packit Service |
ea0369 |
va_list args)
|
|
Packit Service |
ea0369 |
G_GNUC_PRINTF(4, 0);
|
|
Packit Service |
ea0369 |
xmlNodePtr gvir_config_xml_parse(const char *xml,
|
|
Packit Service |
ea0369 |
const char *root_node,
|
|
Packit Service |
ea0369 |
GError **err);
|
|
Packit Service |
ea0369 |
typedef gboolean (*GVirConfigXmlNodeIterator)(xmlNodePtr node, gpointer opaque);
|
|
Packit Service |
ea0369 |
void gvir_config_xml_foreach_child(xmlNodePtr node,
|
|
Packit Service |
ea0369 |
GVirConfigXmlNodeIterator iter_func,
|
|
Packit Service |
ea0369 |
gpointer opaque);
|
|
Packit Service |
ea0369 |
xmlNode * gvir_config_xml_get_element (xmlNode *node, ...)
|
|
Packit Service |
ea0369 |
G_GNUC_NULL_TERMINATED;
|
|
Packit Service |
ea0369 |
const char * gvir_config_xml_get_child_element_content (xmlNode *node,
|
|
Packit Service |
ea0369 |
const char *child_name);
|
|
Packit Service |
ea0369 |
const char *gvir_config_xml_get_attribute_content(xmlNodePtr node,
|
|
Packit Service |
ea0369 |
const char *attr_name);
|
|
Packit Service |
ea0369 |
char *gvir_config_xml_node_to_string(xmlNodePtr node);
|
|
Packit Service |
ea0369 |
const char *gvir_config_genum_get_nick (GType enum_type, gint value);
|
|
Packit Service |
ea0369 |
int gvir_config_genum_get_value (GType enum_type, const char *nick, gint default_value);
|
|
Packit Service |
ea0369 |
G_END_DECLS
|
|
Packit Service |
ea0369 |
|
|
Packit Service |
ea0369 |
#endif /* __LIBVIRT_GCONFIG_HELPERS_PRIVATE_H__ */
|