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

<refnamediv>
<refname>CamelPOP3Engine</refname>
<refpurpose></refpurpose>
<!--[<xref linkend="desc" endterm="desc.title"/>]-->
</refnamediv>

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

<synopsis>
                    <link linkend="CamelPOP3Engine">CamelPOP3Engine</link>;
                    <link linkend="CamelPOP3Command">CamelPOP3Command</link>;
enum                <link linkend="camel-pop3-engine-t">camel_pop3_engine_t</link>;
enum                <link linkend="camel-pop3-command-t">camel_pop3_command_t</link>;
<link linkend="void">void</link>                (<link linkend="CamelPOP3CommandFunc">*CamelPOP3CommandFunc</link>)             (<link linkend="CamelPOP3Engine">CamelPOP3Engine</link> *pe,
                                                         <link linkend="CamelPOP3Stream">CamelPOP3Stream</link> *stream,
                                                         <link linkend="void">void</link> *data);
<link linkend="CamelPOP3Engine">CamelPOP3Engine</link>*    <link linkend="camel-pop3-engine-new">camel_pop3_engine_new</link>               (<link linkend="CamelStream">CamelStream</link> *source,
                                                         <link linkend="guint32">guint32</link> flags);
<link linkend="void">void</link>                <link linkend="camel-pop3-engine-reget-capabilities">camel_pop3_engine_reget_capabilities</link>
                                                        (<link linkend="CamelPOP3Engine">CamelPOP3Engine</link> *engine);
<link linkend="void">void</link>                <link linkend="camel-pop3-engine-command-free">camel_pop3_engine_command_free</link>      (<link linkend="CamelPOP3Engine">CamelPOP3Engine</link> *pe,
                                                         <link linkend="CamelPOP3Command">CamelPOP3Command</link> *pc);
<link linkend="int">int</link>                 <link linkend="camel-pop3-engine-iterate">camel_pop3_engine_iterate</link>           (<link linkend="CamelPOP3Engine">CamelPOP3Engine</link> *pe,
                                                         <link linkend="CamelPOP3Command">CamelPOP3Command</link> *pc);
<link linkend="CamelPOP3Command">CamelPOP3Command</link>*   <link linkend="camel-pop3-engine-command-new">camel_pop3_engine_command_new</link>       (<link linkend="CamelPOP3Engine">CamelPOP3Engine</link> *pe,
                                                         <link linkend="guint32">guint32</link> flags,
                                                         <link linkend="CamelPOP3CommandFunc">CamelPOP3CommandFunc</link> func,
                                                         <link linkend="void">void</link> *data,
                                                         const <link linkend="char">char</link> *fmt,
                                                         ...);
</synopsis>
</refsynopsisdiv>









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

</para>
</refsect1>

<refsect1 id="camel-CamelPOP3Engine.details" role="details">
<title role="details.title">Details</title>
<refsect2 id="CamelPOP3Engine" role="struct">
<title>CamelPOP3Engine</title>
<indexterm zone="CamelPOP3Engine"><primary>CamelPOP3Engine</primary></indexterm><programlisting>typedef struct {
	CamelObject parent;
	
	guint32 flags;
	
	camel_pop3_engine_t state;

	GList *auth;		/* authtypes supported */

	guint32 capa;		/* capabilities */
	char *apop;		/* apop time string */

	unsigned char *line;	/* current line buffer */
	unsigned int linelen;

	struct _CamelPOP3Stream *stream;

	unsigned int sentlen;	/* data sent (so we dont overflow network buffer) */

	EDList active;		/* active commands */
	EDList queue;		/* queue of waiting commands */
	EDList done;		/* list of done commands, awaiting free */

	CamelPOP3Command *current; /* currently busy (downloading) response */
} CamelPOP3Engine;
</programlisting>
<para>

</para></refsect2>
<refsect2 id="CamelPOP3Command" role="struct">
<title>CamelPOP3Command</title>
<indexterm zone="CamelPOP3Command"><primary>CamelPOP3Command</primary></indexterm><programlisting>typedef struct {
	struct _CamelPOP3Command *next;
	struct _CamelPOP3Command *prev;

	guint32 flags;
	camel_pop3_command_t state;

	CamelPOP3CommandFunc func;
	void *func_data;

	int data_size;
	char *data;
} CamelPOP3Command;
</programlisting>
<para>

</para></refsect2>
<refsect2 id="camel-pop3-engine-t" role="enum">
<title>enum camel_pop3_engine_t</title>
<indexterm zone="camel-pop3-engine-t"><primary>camel_pop3_engine_t</primary></indexterm><programlisting>typedef enum {
	CAMEL_POP3_ENGINE_DISCONNECT = 0,
	CAMEL_POP3_ENGINE_AUTH,
	CAMEL_POP3_ENGINE_TRANSACTION,
	CAMEL_POP3_ENGINE_UPDATE
} camel_pop3_engine_t;
</programlisting>
<para>

</para></refsect2>
<refsect2 id="camel-pop3-command-t" role="enum">
<title>enum camel_pop3_command_t</title>
<indexterm zone="camel-pop3-command-t"><primary>camel_pop3_command_t</primary></indexterm><programlisting>typedef enum {
	CAMEL_POP3_COMMAND_IDLE = 0, /* command created or queued, not yet sent (e.g. non pipelined server) */
	CAMEL_POP3_COMMAND_DISPATCHED, /* command sent to server */

	/* completion codes */
	CAMEL_POP3_COMMAND_OK,	/* plain ok response */
	CAMEL_POP3_COMMAND_DATA, /* processing command response */
	CAMEL_POP3_COMMAND_ERR	/* error response */
} camel_pop3_command_t;
</programlisting>
<para>

</para></refsect2>
<refsect2 id="CamelPOP3CommandFunc" role="function">
<title>CamelPOP3CommandFunc ()</title>
<indexterm zone="CamelPOP3CommandFunc"><primary>CamelPOP3CommandFunc</primary></indexterm><programlisting><link linkend="void">void</link>                (*CamelPOP3CommandFunc)             (<link linkend="CamelPOP3Engine">CamelPOP3Engine</link> *pe,
                                                         <link linkend="CamelPOP3Stream">CamelPOP3Stream</link> *stream,
                                                         <link linkend="void">void</link> *data);</programlisting>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>pe</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>stream</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>data</parameter>&nbsp;:</term>
<listitem><simpara>


</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-pop3-engine-new" role="function">
<title>camel_pop3_engine_new ()</title>
<indexterm zone="camel-pop3-engine-new"><primary>camel_pop3_engine_new</primary></indexterm><programlisting><link linkend="CamelPOP3Engine">CamelPOP3Engine</link>*    camel_pop3_engine_new               (<link linkend="CamelStream">CamelStream</link> *source,
                                                         <link linkend="guint32">guint32</link> flags);</programlisting>
<para>
Returns a NULL stream.  A null stream is always at eof, and
always returns success for all reads and writes.</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>source</parameter>&nbsp;:</term>
<listitem><simpara> source stream
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>flags</parameter>&nbsp;:</term>
<listitem><simpara> engine flags
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> the stream
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-pop3-engine-reget-capabilities" role="function">
<title>camel_pop3_engine_reget_capabilities ()</title>
<indexterm zone="camel-pop3-engine-reget-capabilities"><primary>camel_pop3_engine_reget_capabilities</primary></indexterm><programlisting><link linkend="void">void</link>                camel_pop3_engine_reget_capabilities
                                                        (<link linkend="CamelPOP3Engine">CamelPOP3Engine</link> *engine);</programlisting>
<para>
Regets server capabilities (needed after a STLS command is issued for example).</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>engine</parameter>&nbsp;:</term>
<listitem><simpara> pop3 engine
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-pop3-engine-command-free" role="function">
<title>camel_pop3_engine_command_free ()</title>
<indexterm zone="camel-pop3-engine-command-free"><primary>camel_pop3_engine_command_free</primary></indexterm><programlisting><link linkend="void">void</link>                camel_pop3_engine_command_free      (<link linkend="CamelPOP3Engine">CamelPOP3Engine</link> *pe,
                                                         <link linkend="CamelPOP3Command">CamelPOP3Command</link> *pc);</programlisting>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>pe</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>pc</parameter>&nbsp;:</term>
<listitem><simpara>


</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-pop3-engine-iterate" role="function">
<title>camel_pop3_engine_iterate ()</title>
<indexterm zone="camel-pop3-engine-iterate"><primary>camel_pop3_engine_iterate</primary></indexterm><programlisting><link linkend="int">int</link>                 camel_pop3_engine_iterate           (<link linkend="CamelPOP3Engine">CamelPOP3Engine</link> *pe,
                                                         <link linkend="CamelPOP3Command">CamelPOP3Command</link> *pc);</programlisting>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>pe</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>pc</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara>


</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2 id="camel-pop3-engine-command-new" role="function">
<title>camel_pop3_engine_command_new ()</title>
<indexterm zone="camel-pop3-engine-command-new"><primary>camel_pop3_engine_command_new</primary></indexterm><programlisting><link linkend="CamelPOP3Command">CamelPOP3Command</link>*   camel_pop3_engine_command_new       (<link linkend="CamelPOP3Engine">CamelPOP3Engine</link> *pe,
                                                         <link linkend="guint32">guint32</link> flags,
                                                         <link linkend="CamelPOP3CommandFunc">CamelPOP3CommandFunc</link> func,
                                                         <link linkend="void">void</link> *data,
                                                         const <link linkend="char">char</link> *fmt,
                                                         ...);</programlisting>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>pe</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>flags</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>func</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>data</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>fmt</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>...</parameter>&nbsp;:</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara>


</simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>




</refentry>
