<refentry id="camel-CamelFilterDriver">
<refmeta>
<refentrytitle role="top_of_page" id="camel-CamelFilterDriver.top_of_page">CamelFilterDriver</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>CAMEL Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>CamelFilterDriver</refname>
<refpurpose></refpurpose>
</refnamediv>

<refsynopsisdiv id="camel-CamelFilterDriver.synopsis" role="synopsis">
<title role="synopsis.title">Synopsis</title>

<synopsis>
struct              <link linkend="CamelFilterDriver">CamelFilterDriver</link>;
<link linkend="CamelFolder">CamelFolder</link> *       (<link linkend="CamelFilterGetFolderFunc">*CamelFilterGetFolderFunc</link>)         (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *driver,
                                                         const <link linkend="char">char</link> *uri,
                                                         <link linkend="void">void</link> *data,
                                                         <link linkend="CamelException">CamelException</link> *ex);
<link linkend="CamelFilterDriver">CamelFilterDriver</link> * <link linkend="camel-filter-driver-new">camel_filter_driver_new</link>             (<link linkend="CamelSession">CamelSession</link> *);
<link linkend="void">void</link>                <link linkend="camel-filter-driver-set-logfile">camel_filter_driver_set_logfile</link>     (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="FILE--CAPS">FILE</link> *logfile);
<link linkend="void">void</link>                <link linkend="camel-filter-driver-set-status-func">camel_filter_driver_set_status_func</link> (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFilterStatusFunc">CamelFilterStatusFunc</link> *func,
                                                         <link linkend="void">void</link> *data);
<link linkend="void">void</link>                <link linkend="camel-filter-driver-set-shell-func">camel_filter_driver_set_shell_func</link>  (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFilterShellFunc">CamelFilterShellFunc</link> *func,
                                                         <link linkend="void">void</link> *data);
<link linkend="void">void</link>                <link linkend="camel-filter-driver-set-play-sound-func">camel_filter_driver_set_play_sound_func</link>
                                                        (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFilterPlaySoundFunc">CamelFilterPlaySoundFunc</link> *func,
                                                         <link linkend="void">void</link> *data);
<link linkend="void">void</link>                <link linkend="camel-filter-driver-set-system-beep-func">camel_filter_driver_set_system_beep_func</link>
                                                        (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFilterSystemBeepFunc">CamelFilterSystemBeepFunc</link> *func,
                                                         <link linkend="void">void</link> *data);
<link linkend="void">void</link>                <link linkend="camel-filter-driver-set-folder-func">camel_filter_driver_set_folder_func</link> (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFilterGetFolderFunc">CamelFilterGetFolderFunc</link> fetcher,
                                                         <link linkend="void">void</link> *data);
<link linkend="void">void</link>                <link linkend="camel-filter-driver-set-default-folder">camel_filter_driver_set_default_folder</link>
                                                        (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFolder">CamelFolder</link> *def);
<link linkend="void">void</link>                <link linkend="camel-filter-driver-add-rule">camel_filter_driver_add_rule</link>        (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         const <link linkend="char">char</link> *name,
                                                         const <link linkend="char">char</link> *match,
                                                         const <link linkend="char">char</link> *action);
<link linkend="int">int</link>                 <link linkend="camel-filter-driver-remove-rule-by-name">camel_filter_driver_remove_rule_by_name</link>
                                                        (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         const <link linkend="char">char</link> *name);
<link linkend="void">void</link>                <link linkend="camel-filter-driver-flush">camel_filter_driver_flush</link>           (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *driver,
                                                         <link linkend="CamelException">CamelException</link> *ex);
<link linkend="int">int</link>                 <link linkend="camel-filter-driver-filter-message">camel_filter_driver_filter_message</link>  (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *driver,
                                                         <link linkend="CamelMimeMessage">CamelMimeMessage</link> *message,
                                                         <link linkend="CamelMessageInfo">CamelMessageInfo</link> *info,
                                                         const <link linkend="char">char</link> *uid,
                                                         <link linkend="CamelFolder">CamelFolder</link> *source,
                                                         const <link linkend="char">char</link> *source_url,
                                                         const <link linkend="char">char</link> *original_source_url,
                                                         <link linkend="CamelException">CamelException</link> *ex);
<link linkend="int">int</link>                 <link linkend="camel-filter-driver-filter-mbox">camel_filter_driver_filter_mbox</link>     (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *driver,
                                                         const <link linkend="char">char</link> *mbox,
                                                         const <link linkend="char">char</link> *original_source_url,
                                                         <link linkend="CamelException">CamelException</link> *ex);
<link linkend="int">int</link>                 <link linkend="camel-filter-driver-filter-folder">camel_filter_driver_filter_folder</link>   (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *driver,
                                                         <link linkend="CamelFolder">CamelFolder</link> *folder,
                                                         <link linkend="CamelUIDCache">CamelUIDCache</link> *cache,
                                                         <link linkend="GPtrArray">GPtrArray</link> *uids,
                                                         <link linkend="gboolean">gboolean</link> remove,
                                                         <link linkend="CamelException">CamelException</link> *ex);
<link linkend="void">void</link>                <link linkend="camel-filter-driver-expand-option">camel_filter_driver_expand_option</link>   (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="GString">GString</link> *s,
                                                         <link linkend="GString">GString</link> *action,
                                                         <link linkend="struct-filter-option">struct filter_option</link> *op);
<link linkend="int">int</link>                 <link linkend="camel-filter-driver-rule-count">camel_filter_driver_rule_count</link>      (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d);
struct <link linkend="filter-option">filter_option</link> * <link linkend="camel-filter-driver-rule-get">camel_filter_driver_rule_get</link>     (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="int">int</link> n);
</synopsis>
</refsynopsisdiv>









<refsect1 id="camel-CamelFilterDriver.description" role="desc">
<title role="desc.title">Description</title>
<para>
</para>
</refsect1>

<refsect1 id="camel-CamelFilterDriver.details" role="details">
<title role="details.title">Details</title>
<refsect2 id="CamelFilterDriver" role="struct">
<title>struct CamelFilterDriver</title>
<indexterm zone="CamelFilterDriver"><primary sortas="CamelFilterDriver">CamelFilterDriver</primary></indexterm><programlisting>struct CamelFilterDriver {
	CamelObject parent;
	
	struct _CamelFilterDriverPrivate *priv;
};
</programlisting>
<para>
</para></refsect2>
<refsect2 id="CamelFilterGetFolderFunc" role="function">
<title>CamelFilterGetFolderFunc ()</title>
<indexterm zone="CamelFilterGetFolderFunc"><primary sortas="CamelFilterGetFolderFunc">CamelFilterGetFolderFunc</primary></indexterm><programlisting><link linkend="CamelFolder">CamelFolder</link> *       (*CamelFilterGetFolderFunc)         (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *driver,
                                                         const <link linkend="char">char</link> *uri,
                                                         <link linkend="void">void</link> *data,
                                                         <link linkend="CamelException">CamelException</link> *ex);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>driver</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>uri</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>data</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>ex</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-new" role="function">
<title>camel_filter_driver_new ()</title>
<indexterm zone="camel-filter-driver-new"><primary sortas="camel_filter_driver_new">camel_filter_driver_new</primary></indexterm><programlisting><link linkend="CamelFilterDriver">CamelFilterDriver</link> * camel_filter_driver_new             (<link linkend="CamelSession">CamelSession</link> *);</programlisting>
<para>
</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>Param1</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> A new CamelFilterDriver object
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-set-logfile" role="function">
<title>camel_filter_driver_set_logfile ()</title>
<indexterm zone="camel-filter-driver-set-logfile"><primary sortas="camel_filter_driver_set_logfile">camel_filter_driver_set_logfile</primary></indexterm><programlisting><link linkend="void">void</link>                camel_filter_driver_set_logfile     (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="FILE--CAPS">FILE</link> *logfile);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>logfile</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-set-status-func" role="function">
<title>camel_filter_driver_set_status_func ()</title>
<indexterm zone="camel-filter-driver-set-status-func"><primary sortas="camel_filter_driver_set_status_func">camel_filter_driver_set_status_func</primary></indexterm><programlisting><link linkend="void">void</link>                camel_filter_driver_set_status_func (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFilterStatusFunc">CamelFilterStatusFunc</link> *func,
                                                         <link linkend="void">void</link> *data);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>func</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>data</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-set-shell-func" role="function">
<title>camel_filter_driver_set_shell_func ()</title>
<indexterm zone="camel-filter-driver-set-shell-func"><primary sortas="camel_filter_driver_set_shell_func">camel_filter_driver_set_shell_func</primary></indexterm><programlisting><link linkend="void">void</link>                camel_filter_driver_set_shell_func  (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFilterShellFunc">CamelFilterShellFunc</link> *func,
                                                         <link linkend="void">void</link> *data);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>func</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>data</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-set-play-sound-func" role="function">
<title>camel_filter_driver_set_play_sound_func ()</title>
<indexterm zone="camel-filter-driver-set-play-sound-func"><primary sortas="camel_filter_driver_set_play_sound_func">camel_filter_driver_set_play_sound_func</primary></indexterm><programlisting><link linkend="void">void</link>                camel_filter_driver_set_play_sound_func
                                                        (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFilterPlaySoundFunc">CamelFilterPlaySoundFunc</link> *func,
                                                         <link linkend="void">void</link> *data);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>func</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>data</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-set-system-beep-func" role="function">
<title>camel_filter_driver_set_system_beep_func ()</title>
<indexterm zone="camel-filter-driver-set-system-beep-func"><primary sortas="camel_filter_driver_set_system_beep_func">camel_filter_driver_set_system_beep_func</primary></indexterm><programlisting><link linkend="void">void</link>                camel_filter_driver_set_system_beep_func
                                                        (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFilterSystemBeepFunc">CamelFilterSystemBeepFunc</link> *func,
                                                         <link linkend="void">void</link> *data);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>func</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>data</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-set-folder-func" role="function">
<title>camel_filter_driver_set_folder_func ()</title>
<indexterm zone="camel-filter-driver-set-folder-func"><primary sortas="camel_filter_driver_set_folder_func">camel_filter_driver_set_folder_func</primary></indexterm><programlisting><link linkend="void">void</link>                camel_filter_driver_set_folder_func (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFilterGetFolderFunc">CamelFilterGetFolderFunc</link> fetcher,
                                                         <link linkend="void">void</link> *data);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>fetcher</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>data</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-set-default-folder" role="function">
<title>camel_filter_driver_set_default_folder ()</title>
<indexterm zone="camel-filter-driver-set-default-folder"><primary sortas="camel_filter_driver_set_default_folder">camel_filter_driver_set_default_folder</primary></indexterm><programlisting><link linkend="void">void</link>                camel_filter_driver_set_default_folder
                                                        (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="CamelFolder">CamelFolder</link> *def);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>def</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-add-rule" role="function">
<title>camel_filter_driver_add_rule ()</title>
<indexterm zone="camel-filter-driver-add-rule"><primary sortas="camel_filter_driver_add_rule">camel_filter_driver_add_rule</primary></indexterm><programlisting><link linkend="void">void</link>                camel_filter_driver_add_rule        (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         const <link linkend="char">char</link> *name,
                                                         const <link linkend="char">char</link> *match,
                                                         const <link linkend="char">char</link> *action);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>name</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>match</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>action</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-remove-rule-by-name" role="function">
<title>camel_filter_driver_remove_rule_by_name ()</title>
<indexterm zone="camel-filter-driver-remove-rule-by-name"><primary sortas="camel_filter_driver_remove_rule_by_name">camel_filter_driver_remove_rule_by_name</primary></indexterm><programlisting><link linkend="int">int</link>                 camel_filter_driver_remove_rule_by_name
                                                        (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         const <link linkend="char">char</link> *name);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>name</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-flush" role="function">
<title>camel_filter_driver_flush ()</title>
<indexterm zone="camel-filter-driver-flush"><primary sortas="camel_filter_driver_flush">camel_filter_driver_flush</primary></indexterm><programlisting><link linkend="void">void</link>                camel_filter_driver_flush           (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *driver,
                                                         <link linkend="CamelException">CamelException</link> *ex);</programlisting>
<para>
Flush all of the only-once filter actions.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>driver</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>ex</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-filter-message" role="function">
<title>camel_filter_driver_filter_message ()</title>
<indexterm zone="camel-filter-driver-filter-message"><primary sortas="camel_filter_driver_filter_message">camel_filter_driver_filter_message</primary></indexterm><programlisting><link linkend="int">int</link>                 camel_filter_driver_filter_message  (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *driver,
                                                         <link linkend="CamelMimeMessage">CamelMimeMessage</link> *message,
                                                         <link linkend="CamelMessageInfo">CamelMessageInfo</link> *info,
                                                         const <link linkend="char">char</link> *uid,
                                                         <link linkend="CamelFolder">CamelFolder</link> *source,
                                                         const <link linkend="char">char</link> *source_url,
                                                         const <link linkend="char">char</link> *original_source_url,
                                                         <link linkend="CamelException">CamelException</link> *ex);</programlisting>
<para>
Filters a message based on rules defined in the FilterDriver
object. If the source folder (<parameter>source</parameter>) and the uid (<parameter>uid</parameter>) are
provided, the filter will operate on the CamelFolder (which in
certain cases is more efficient than using the default
<link linkend="camel-folder-append-message"><function>camel_folder_append_message()</function></link> function).</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>driver</parameter>&#160;:</term>
<listitem><simpara> CamelFilterDriver
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>message</parameter>&#160;:</term>
<listitem><simpara> message to filter or NULL
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>info</parameter>&#160;:</term>
<listitem><simpara> message info or NULL
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>uid</parameter>&#160;:</term>
<listitem><simpara> message uid or NULL
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>source</parameter>&#160;:</term>
<listitem><simpara> source folder or NULL
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>source_url</parameter>&#160;:</term>
<listitem><simpara> url of source folder or NULL
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>original_source_url</parameter>&#160;:</term>
<listitem><simpara> url of original source folder (pre-movemail) or NULL
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>ex</parameter>&#160;:</term>
<listitem><simpara> exception
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> -1 if errors were encountered during filtering,
otherwise returns 0.

</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-filter-mbox" role="function">
<title>camel_filter_driver_filter_mbox ()</title>
<indexterm zone="camel-filter-driver-filter-mbox"><primary sortas="camel_filter_driver_filter_mbox">camel_filter_driver_filter_mbox</primary></indexterm><programlisting><link linkend="int">int</link>                 camel_filter_driver_filter_mbox     (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *driver,
                                                         const <link linkend="char">char</link> *mbox,
                                                         const <link linkend="char">char</link> *original_source_url,
                                                         <link linkend="CamelException">CamelException</link> *ex);</programlisting>
<para>
Filters an mbox file based on rules defined in the FilterDriver
object. Is more efficient as it doesn't need to open the folder
through Camel directly.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>driver</parameter>&#160;:</term>
<listitem><simpara> CamelFilterDriver
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>mbox</parameter>&#160;:</term>
<listitem><simpara> mbox filename to be filtered
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>original_source_url</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>ex</parameter>&#160;:</term>
<listitem><simpara> exception
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> -1 if errors were encountered during filtering,
otherwise returns 0.

</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-filter-folder" role="function">
<title>camel_filter_driver_filter_folder ()</title>
<indexterm zone="camel-filter-driver-filter-folder"><primary sortas="camel_filter_driver_filter_folder">camel_filter_driver_filter_folder</primary></indexterm><programlisting><link linkend="int">int</link>                 camel_filter_driver_filter_folder   (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *driver,
                                                         <link linkend="CamelFolder">CamelFolder</link> *folder,
                                                         <link linkend="CamelUIDCache">CamelUIDCache</link> *cache,
                                                         <link linkend="GPtrArray">GPtrArray</link> *uids,
                                                         <link linkend="gboolean">gboolean</link> remove,
                                                         <link linkend="CamelException">CamelException</link> *ex);</programlisting>
<para>
Filters a folder based on rules defined in the FilterDriver
object.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>driver</parameter>&#160;:</term>
<listitem><simpara> CamelFilterDriver
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>folder</parameter>&#160;:</term>
<listitem><simpara> CamelFolder to be filtered
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>cache</parameter>&#160;:</term>
<listitem><simpara> UID cache (needed for POP folders)
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>uids</parameter>&#160;:</term>
<listitem><simpara> message uids to be filtered or NULL (as a shortcut to filter all messages)
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>remove</parameter>&#160;:</term>
<listitem><simpara> TRUE to mark filtered messages as deleted
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>ex</parameter>&#160;:</term>
<listitem><simpara> exception
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara> -1 if errors were encountered during filtering,
otherwise returns 0.

</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-expand-option" role="function">
<title>camel_filter_driver_expand_option ()</title>
<indexterm zone="camel-filter-driver-expand-option"><primary sortas="camel_filter_driver_expand_option">camel_filter_driver_expand_option</primary></indexterm><programlisting><link linkend="void">void</link>                camel_filter_driver_expand_option   (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="GString">GString</link> *s,
                                                         <link linkend="GString">GString</link> *action,
                                                         <link linkend="struct-filter-option">struct filter_option</link> *op);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>s</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>action</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>op</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-rule-count" role="function">
<title>camel_filter_driver_rule_count ()</title>
<indexterm zone="camel-filter-driver-rule-count"><primary sortas="camel_filter_driver_rule_count">camel_filter_driver_rule_count</primary></indexterm><programlisting><link linkend="int">int</link>                 camel_filter_driver_rule_count      (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-filter-driver-rule-get" role="function">
<title>camel_filter_driver_rule_get ()</title>
<indexterm zone="camel-filter-driver-rule-get"><primary sortas="camel_filter_driver_rule_get">camel_filter_driver_rule_get</primary></indexterm><programlisting>struct <link linkend="filter-option">filter_option</link> * camel_filter_driver_rule_get     (<link linkend="CamelFilterDriver">CamelFilterDriver</link> *d,
                                                         <link linkend="int">int</link> n);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>d</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>n</parameter>&#160;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&#160;:</term><listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>




</refentry>
