<?xml version="1.0"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
               "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd" [
<!ENTITY version SYSTEM "version.xml">
]>
<refentry id="PackageKit-egg-debug">
<refmeta>
<refentrytitle role="top_of_page" id="PackageKit-egg-debug.top_of_page">egg-debug</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>PACKAGEKIT Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>egg-debug</refname>
<refpurpose>Debugging functions</refpurpose>
</refnamediv>

<refsynopsisdiv id="PackageKit-egg-debug.synopsis" role="synopsis">
<title role="synopsis.title">Synopsis</title>

<synopsis>
#define             <link linkend="egg-debug">egg_debug</link>                           (...)
#define             <link linkend="egg-warning">egg_warning</link>                         (...)
#define             <link linkend="egg-error">egg_error</link>                           (...)
<link linkend="gboolean">gboolean</link>            <link linkend="egg-debug-init">egg_debug_init</link>                      (<link linkend="gint">gint</link> *argc,
                                                         <link linkend="gchar">gchar</link> ***argv);
<link linkend="GOptionGroup">GOptionGroup</link> *      <link linkend="egg-debug-get-option-group">egg_debug_get_option_group</link>          (void);
<link linkend="gboolean">gboolean</link>            <link linkend="egg-debug-is-verbose">egg_debug_is_verbose</link>                (void);
<link linkend="void">void</link>                <link linkend="egg-debug-backtrace">egg_debug_backtrace</link>                 (void);
<link linkend="void">void</link>                <link linkend="egg-debug-set-log-filename">egg_debug_set_log_filename</link>          (const <link linkend="gchar">gchar</link> *filename);
<link linkend="void">void</link>                <link linkend="egg-debug-real">egg_debug_real</link>                      (const <link linkend="gchar">gchar</link> *func,
                                                         const <link linkend="gchar">gchar</link> *file,
                                                         <link linkend="gint">gint</link> line,
                                                         const <link linkend="gchar">gchar</link> *format,
                                                         ...);
<link linkend="void">void</link>                <link linkend="egg-warning-real">egg_warning_real</link>                    (const <link linkend="gchar">gchar</link> *func,
                                                         const <link linkend="gchar">gchar</link> *file,
                                                         <link linkend="gint">gint</link> line,
                                                         const <link linkend="gchar">gchar</link> *format,
                                                         ...);
<link linkend="void">void</link>                <link linkend="egg-error-real">egg_error_real</link>                      (const <link linkend="gchar">gchar</link> *func,
                                                         const <link linkend="gchar">gchar</link> *file,
                                                         <link linkend="gint">gint</link> line,
                                                         const <link linkend="gchar">gchar</link> *format,
                                                         ...);
</synopsis>
</refsynopsisdiv>









<refsect1 id="PackageKit-egg-debug.description" role="desc">
<title role="desc.title">Description</title>
<para>
This file contains functions that can be used for debugging.</para>
<para>
</para>
</refsect1>

<refsect1 id="PackageKit-egg-debug.details" role="details">
<title role="details.title">Details</title>
<refsect2 id="egg-debug" role="macro">
<title>egg_debug()</title>
<indexterm zone="egg-debug"><primary sortas="egg_debug">egg_debug</primary></indexterm><programlisting>#define             egg_debug(...)</programlisting>
<para>
Non critical debugging</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>...</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="egg-warning" role="macro">
<title>egg_warning()</title>
<indexterm zone="egg-warning"><primary sortas="egg_warning">egg_warning</primary></indexterm><programlisting>#define             egg_warning(...)</programlisting>
<para>
Important debugging</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>...</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="egg-error" role="macro">
<title>egg_error()</title>
<indexterm zone="egg-error"><primary sortas="egg_error">egg_error</primary></indexterm><programlisting>#define             egg_error(...)</programlisting>
<para>
Critical debugging, with exit</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>...</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="egg-debug-init" role="function">
<title>egg_debug_init ()</title>
<indexterm zone="egg-debug-init"><primary sortas="egg_debug_init">egg_debug_init</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            egg_debug_init                      (<link linkend="gint">gint</link> *argc,
                                                         <link linkend="gchar">gchar</link> ***argv);</programlisting>
<para>
Parses command line arguments.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>argc</parameter>&#160;:</term>
<listitem><simpara> a pointer to the number of command line arguments.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>argv</parameter>&#160;:</term>
<listitem><simpara> a pointer to the array of command line arguments.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> <link linkend="TRUE--CAPS"><literal>TRUE</literal></link> if initialization succeeded, otherwise <link linkend="FALSE--CAPS"><literal>FALSE</literal></link>.
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="egg-debug-get-option-group" role="function">
<title>egg_debug_get_option_group ()</title>
<indexterm zone="egg-debug-get-option-group"><primary sortas="egg_debug_get_option_group">egg_debug_get_option_group</primary></indexterm><programlisting><link linkend="GOptionGroup">GOptionGroup</link> *      egg_debug_get_option_group          (void);</programlisting>
<para>
Returns a <link linkend="GOptionGroup"><type>GOptionGroup</type></link> for the commandline arguments recognized
by debugging. You should add this group to your <link linkend="GOptionContext"><type>GOptionContext</type></link>
with <link linkend="g-option-context-add-group"><function>g_option_context_add_group()</function></link>, if you are using
<link linkend="g-option-context-parse"><function>g_option_context_parse()</function></link> to parse your commandline arguments.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> a <link linkend="GOptionGroup"><type>GOptionGroup</type></link> for the commandline arguments
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="egg-debug-is-verbose" role="function">
<title>egg_debug_is_verbose ()</title>
<indexterm zone="egg-debug-is-verbose"><primary sortas="egg_debug_is_verbose">egg_debug_is_verbose</primary></indexterm><programlisting><link linkend="gboolean">gboolean</link>            egg_debug_is_verbose                (void);</programlisting>
<para>
</para>
<para>
</para><variablelist role="params">
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> TRUE if we have debugging enabled
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="egg-debug-backtrace" role="function">
<title>egg_debug_backtrace ()</title>
<indexterm zone="egg-debug-backtrace"><primary sortas="egg_debug_backtrace">egg_debug_backtrace</primary></indexterm><programlisting><link linkend="void">void</link>                egg_debug_backtrace                 (void);</programlisting>
<para>
</para>
<para>
</para></refsect2>
<refsect2 id="egg-debug-set-log-filename" role="function">
<title>egg_debug_set_log_filename ()</title>
<indexterm zone="egg-debug-set-log-filename"><primary sortas="egg_debug_set_log_filename">egg_debug_set_log_filename</primary></indexterm><programlisting><link linkend="void">void</link>                egg_debug_set_log_filename          (const <link linkend="gchar">gchar</link> *filename);</programlisting>
<para>
</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>filename</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="egg-debug-real" role="function">
<title>egg_debug_real ()</title>
<indexterm zone="egg-debug-real"><primary sortas="egg_debug_real">egg_debug_real</primary></indexterm><programlisting><link linkend="void">void</link>                egg_debug_real                      (const <link linkend="gchar">gchar</link> *func,
                                                         const <link linkend="gchar">gchar</link> *file,
                                                         <link linkend="gint">gint</link> line,
                                                         const <link linkend="gchar">gchar</link> *format,
                                                         ...);</programlisting>
<para>
</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>func</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>file</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>line</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>format</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>...</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="egg-warning-real" role="function">
<title>egg_warning_real ()</title>
<indexterm zone="egg-warning-real"><primary sortas="egg_warning_real">egg_warning_real</primary></indexterm><programlisting><link linkend="void">void</link>                egg_warning_real                    (const <link linkend="gchar">gchar</link> *func,
                                                         const <link linkend="gchar">gchar</link> *file,
                                                         <link linkend="gint">gint</link> line,
                                                         const <link linkend="gchar">gchar</link> *format,
                                                         ...);</programlisting>
<para>
</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>func</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>file</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>line</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>format</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>...</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="egg-error-real" role="function">
<title>egg_error_real ()</title>
<indexterm zone="egg-error-real"><primary sortas="egg_error_real">egg_error_real</primary></indexterm><programlisting><link linkend="void">void</link>                egg_error_real                      (const <link linkend="gchar">gchar</link> *func,
                                                         const <link linkend="gchar">gchar</link> *file,
                                                         <link linkend="gint">gint</link> line,
                                                         const <link linkend="gchar">gchar</link> *format,
                                                         ...);</programlisting>
<para>
</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>func</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>file</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>line</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>format</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>...</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>




</refentry>
