nntpgrab_plugin_nntp.h File Reference

#include "nntpgrab_plugin_base.h"

Go to the source code of this file.


Data Structures

struct   _plugin_nntp_imported_funcs

Typedefs

typedef struct
_plugin_nntp_imported_funcs 
PluginNNTPImportedFuncs

Functions

gboolean  nntpgrab_plugin_nntp_initialize (PluginNNTPImportedFuncs funcs)
  Initialize the plugin.
int  nntpgrab_plugin_nntp_get_version (void)
  Return the API version of the plugin.
gboolean  nntpgrab_plugin_nntp_get_is_connected (int conn_id)
  Function to check is the connection is still alive.
NNTPGrabErrCode  nntpgrab_plugin_nntp_connect (const char *hostname, int port, const char *username, const char *password, gboolean use_ssl, char **errmsg, int *conn_id, gpointer data)
  Connect to the specified usenet server with the given parameters.
void  nntpgrab_plugin_nntp_disconnect (int conn_id, gpointer data)
  Disconnect from the connected server.
NNTPGrabErrCode  nntpgrab_plugin_nntp_get_article_by_message_id (int conn_id, const char *message_id, const char **headers, const char *filename, gpointer cb_data)
  Get a article from the connected usenet server.
NNTPGrabErrCode  nntpgrab_plugin_nntp_group (int conn_id, const char *newsgroup, int *num_articles, gint64 *start_article, gint64 *end_article, gpointer data)
  Set the active newsgroup.
NNTPGrabErrCode  nntpgrab_plugin_nntp_xover (int conn_id, gint64 start_range, gint64 end_range, gpointer data)
  Retrieve a list of the available messages in active newsgroup.

Typedef Documentation

typedef struct _plugin_nntp_imported_funcs PluginNNTPImportedFuncs


Function Documentation

NNTPGrabErrCode nntpgrab_plugin_nntp_connect ( const char *  hostname,
int  port,
const char *  username,
const char *  password,
gboolean  use_ssl,
char **  errmsg,
int *  conn_id,
gpointer  data  
)

Connect to the specified usenet server with the given parameters.

Returns:
ERROR_NONE when the connection and login are successfull

void nntpgrab_plugin_nntp_disconnect ( int  conn_id,
gpointer  data  
)

Disconnect from the connected server.

NNTPGrabErrCode nntpgrab_plugin_nntp_get_article_by_message_id ( int  conn_id,
const char *  message_id,
const char **  headers,
const char *  filename,
gpointer  cb_data  
)

Get a article from the connected usenet server.

Returns:
ERROR_NONE on success

gboolean nntpgrab_plugin_nntp_get_is_connected ( int  conn_id  ) 

Function to check is the connection is still alive.

Returns:
TRUE when the connection is still alive

int nntpgrab_plugin_nntp_get_version ( void   ) 

Return the API version of the plugin.

This is used to verify that the plugin is compatible with the interface the NNTPGrab Core expects

Returns:
NNTPGRAB_PLUGIN_NNTP_API_VERSION

NNTPGrabErrCode nntpgrab_plugin_nntp_group ( int  conn_id,
const char *  newsgroup,
int *  num_articles,
gint64 *  start_article,
gint64 *  end_article,
gpointer  data  
)

Set the active newsgroup.

gboolean nntpgrab_plugin_nntp_initialize ( PluginNNTPImportedFuncs  funcs  ) 

Initialize the plugin.

Returns:
TRUE when the initialization was successfull

NNTPGrabErrCode nntpgrab_plugin_nntp_xover ( int  conn_id,
gint64  start_range,
gint64  end_range,
gpointer  data  
)

Retrieve a list of the available messages in active newsgroup.


Generated on Thu May 21 21:25:05 2009 for NNTPGrab by  1.5.4