<refentry id="TrackerClient">
<refmeta>
<refentrytitle role="top_of_page" id="TrackerClient.top_of_page">TrackerClient</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>LIBTRACKER-CLIENT Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>TrackerClient</refname>
<refpurpose>A client library for querying and inserting
data in Tracker.</refpurpose>
</refnamediv>

<refsynopsisdiv id="TrackerClient.synopsis" role="synopsis">
<title role="synopsis.title">Synopsis</title>

<synopsis>

#include &lt;libtracker-client/tracker-client.h&gt;

#define             <link linkend="TRACKER-DBUS-SERVICE--CAPS">TRACKER_DBUS_SERVICE</link>
#define             <link linkend="TRACKER-DBUS-OBJECT--CAPS">TRACKER_DBUS_OBJECT</link>
#define             <link linkend="TRACKER-DBUS-INTERFACE-RESOURCES--CAPS">TRACKER_DBUS_INTERFACE_RESOURCES</link>
#define             <link linkend="TRACKER-DBUS-INTERFACE-STATISTICS--CAPS">TRACKER_DBUS_INTERFACE_STATISTICS</link>
                    <link linkend="TrackerClient-struct">TrackerClient</link>;
                    <link linkend="TrackerClientClass">TrackerClientClass</link>;
enum                <link linkend="TrackerClientFlags">TrackerClientFlags</link>;
<link linkend="TrackerClient">TrackerClient</link> *     <link linkend="tracker-client-new">tracker_client_new</link>                  (<link linkend="TrackerClientFlags">TrackerClientFlags</link> flags,
                                                         <link linkend="gint">gint</link> timeout);
</synopsis>
</refsynopsisdiv>

<refsect1 id="TrackerClient.object-hierarchy" role="object_hierarchy">
<title role="object_hierarchy.title">Object Hierarchy</title>
<synopsis>
  <link linkend="GObject">GObject</link>
   +----TrackerClient
</synopsis>
</refsect1>





<refsect1 id="TrackerClient.properties" role="properties">
<title role="properties.title">Properties</title>
<synopsis>
  &quot;<link linkend="TrackerClient--enable-warnings">enable-warnings</link>&quot;          <link linkend="gboolean">gboolean</link>              : Read / Write / Construct
  &quot;<link linkend="TrackerClient--timeout">timeout</link>&quot;                  <link linkend="gint">gint</link>                  : Read / Write / Construct
</synopsis>
</refsect1>



<refsect1 id="TrackerClient.description" role="desc">
<title role="desc.title">Description</title>
<para>
This API is for applications which want to integrate with Tracker
either by storing their data or by querying it. They are also not
limited to their application's data. Other data mined by other
applications is also available in some cases.</para>
<para>
</para>
</refsect1>

<refsect1 id="TrackerClient.details" role="details">
<title role="details.title">Details</title>
<refsect2 id="TRACKER-DBUS-SERVICE--CAPS" role="macro">
<title>TRACKER_DBUS_SERVICE</title>
<indexterm zone="TRACKER-DBUS-SERVICE--CAPS"><primary sortas="TRACKER_DBUS_SERVICE">TRACKER_DBUS_SERVICE</primary></indexterm><programlisting>#define TRACKER_DBUS_SERVICE              "org.freedesktop.Tracker1"
</programlisting>
<para>
</para></refsect2>
<refsect2 id="TRACKER-DBUS-OBJECT--CAPS" role="macro">
<title>TRACKER_DBUS_OBJECT</title>
<indexterm zone="TRACKER-DBUS-OBJECT--CAPS"><primary sortas="TRACKER_DBUS_OBJECT">TRACKER_DBUS_OBJECT</primary></indexterm><programlisting>#define TRACKER_DBUS_OBJECT               "/org/freedesktop/Tracker1"
</programlisting>
<para>
</para></refsect2>
<refsect2 id="TRACKER-DBUS-INTERFACE-RESOURCES--CAPS" role="macro">
<title>TRACKER_DBUS_INTERFACE_RESOURCES</title>
<indexterm zone="TRACKER-DBUS-INTERFACE-RESOURCES--CAPS"><primary sortas="TRACKER_DBUS_INTERFACE_RESOURCES">TRACKER_DBUS_INTERFACE_RESOURCES</primary></indexterm><programlisting>#define TRACKER_DBUS_INTERFACE_RESOURCES  "org.freedesktop.Tracker1.Resources"
</programlisting>
<para>
</para></refsect2>
<refsect2 id="TRACKER-DBUS-INTERFACE-STATISTICS--CAPS" role="macro">
<title>TRACKER_DBUS_INTERFACE_STATISTICS</title>
<indexterm zone="TRACKER-DBUS-INTERFACE-STATISTICS--CAPS"><primary sortas="TRACKER_DBUS_INTERFACE_STATISTICS">TRACKER_DBUS_INTERFACE_STATISTICS</primary></indexterm><programlisting>#define TRACKER_DBUS_INTERFACE_STATISTICS "org.freedesktop.Tracker1.Statistics"
</programlisting>
<para>
</para></refsect2>
<refsect2 id="TrackerClient-struct" role="struct">
<title>TrackerClient</title>
<indexterm zone="TrackerClient-struct"><primary sortas="TrackerClient">TrackerClient</primary></indexterm><programlisting>typedef struct _TrackerClient TrackerClient;</programlisting>
<para>
</para></refsect2>
<refsect2 id="TrackerClientClass" role="struct">
<title>TrackerClientClass</title>
<indexterm zone="TrackerClientClass"><primary sortas="TrackerClientClass">TrackerClientClass</primary></indexterm><programlisting>typedef struct {
	GObjectClass parent;
} TrackerClientClass;
</programlisting>
<para>
</para></refsect2>
<refsect2 id="TrackerClientFlags" role="enum">
<title>enum TrackerClientFlags</title>
<indexterm zone="TrackerClientFlags"><primary sortas="TrackerClientFlags">TrackerClientFlags</primary></indexterm><programlisting>typedef enum {
	TRACKER_CLIENT_ENABLE_WARNINGS      = 1 &lt;&lt; 0
} TrackerClientFlags;
</programlisting>
<para>
</para>
<para>
</para><variablelist role="enum">
<varlistentry id="TRACKER-CLIENT-ENABLE-WARNINGS--CAPS" role="constant">
<term><literal>TRACKER_CLIENT_ENABLE_WARNINGS</literal></term>
<listitem><simpara> If supplied warnings will be
produced upon erronous situations. This is usually turned off for
applications that want to provide their own error reporting.
</simpara></listitem>
</varlistentry>
</variablelist></refsect2>
<refsect2 id="tracker-client-new" role="function">
<title>tracker_client_new ()</title>
<indexterm zone="tracker-client-new"><primary sortas="tracker_client_new">tracker_client_new</primary></indexterm><programlisting><link linkend="TrackerClient">TrackerClient</link> *     tracker_client_new                  (<link linkend="TrackerClientFlags">TrackerClientFlags</link> flags,
                                                         <link linkend="gint">gint</link> timeout);</programlisting>
<para>
Creates a connection over D-Bus to the Tracker store for doing data
querying and inserting.
</para>
<para>
The <parameter>timeout</parameter> is only used if it is &gt; 0. If it is, then it is used
with <link linkend="dbus-g-proxy-set-default-timeout"><function>dbus_g_proxy_set_default_timeout()</function></link>.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>flags</parameter>&#160;:</term>
<listitem><simpara> This can be one or more combinations of <link linkend="TrackerClientFlags"><type>TrackerClientFlags</type></link>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>timeout</parameter>&#160;:</term>
<listitem><simpara> a <link linkend="gint"><type>gint</type></link> used for D-Bus call timeouts.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> the <link linkend="TrackerClient"><type>TrackerClient</type></link> which should be freed with
<link linkend="g-object-unref"><function>g_object_unref()</function></link> when finished with.
</simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>
<refsect1 id="TrackerClient.property-details" role="property_details">
<title role="property_details.title">Property Details</title>
<refsect2 id="TrackerClient--enable-warnings" role="property"><title>The <literal>&quot;enable-warnings&quot;</literal> property</title>
<indexterm zone="TrackerClient--enable-warnings"><primary sortas="TrackerClient:enable-warnings">TrackerClient:enable-warnings</primary></indexterm><programlisting>  &quot;enable-warnings&quot;          <link linkend="gboolean">gboolean</link>              : Read / Write / Construct</programlisting>
<para>Enable warnings.</para><para>Default value: TRUE</para>
</refsect2>
<refsect2 id="TrackerClient--timeout" role="property"><title>The <literal>&quot;timeout&quot;</literal> property</title>
<indexterm zone="TrackerClient--timeout"><primary sortas="TrackerClient:timeout">TrackerClient:timeout</primary></indexterm><programlisting>  &quot;timeout&quot;                  <link linkend="gint">gint</link>                  : Read / Write / Construct</programlisting>
<para>Timeout.</para><para>Allowed values: &gt;= G_MAXULONG</para>
<para>Default value: -1</para>
</refsect2>
</refsect1>




</refentry>
