schedular_plugin.h File Reference

Go to the source code of this file.


Data Structures

struct   SchedularPlugin
struct   _decoder_data
struct   _download_data

Defines

#define  SCHEDULAR_PLUGIN_TYPE_OBJECT   (schedular_plugin_get_type ())
#define  SCHEDULAR_PLUGIN(object)   (G_TYPE_CHECK_INSTANCE_CAST ((object), SCHEDULAR_PLUGIN_TYPE_OBJECT, SchedularPlugin))
#define  SCHEDULAR_PLUGIN_CLASS(klass)   (G_TYPE_CHECK_CLASS_CAST ((klass), SCHEDULAR_PLUGIN_TYPE_OBJECT, SchedularPluginClass))
#define  IS_SCHEDULAR_PLUGIN(object)   (G_TYPE_CHECK_INSTANCE_TYPE ((object), SCHEDULAR_PLUGIN_TYPE_OBJECT))
#define  IS_SCHEDULAR_PLUGIN_CLASS(klass)   (G_TYPE_CHECK_CLASS_TYPE ((klass), SCHEDULAR_PLUGIN_TYPE_OBJECT))
#define  SCHEDULAR_PLUGIN_GET_CLASS(obj)   (G_TYPE_INSTANCE_GET_CLASS ((obj), SCHEDULAR_PLUGIN_TYPE_OBJECT, SchedularPluginClass))

Typedefs

typedef struct SchedularPlugin  SchedularPlugin
typedef struct _decoder_data  DecoderData
typedef struct _download_data  DownloadData

Functions

GType  schedular_plugin_get_type (void)
gboolean  get_next_part_to_download (SchedularPlugin *schedular, int server_id, NNTPCollection **collection, NNTPFile **file, NNTPPart **part, GThreadPool *poolDecoder)
void  update_part_download_status (NNTPCollection *collection, NNTPFile *file, NNTPPart *part, int server_id, gboolean success, gboolean reset_to_zero, gboolean queue_is_being_paused, gboolean dont_retry_anymore, gpointer nntpconnection)
void  stop_schedular_from_seperate_thread (const char *reason)
gboolean  schedular_plugin_save_queue (char **errmsg)
void  decoder_thread_func (gpointer data, gpointer user_data)
void  download_thread_func (gpointer data, gpointer user_data)
void  schedular_plugin_set_imported_funcs (PluginSchedularImportedFuncs funcs)
void  imported_funcs_task_added (const NNTPCollection *collection, const NNTPFile *file)
void  imported_funcs_task_removed (const char *collection_name, const char *subject, guint64 total_file_size, guint64 total_file_size_remaining)
void  imported_funcs_task_state_changed (const char *collection_name, const char *subject, TaskState old_state, TaskState new_state)
void  imported_funcs_collection_added (const char *collection_name)
void  imported_funcs_collection_removed (const char *collection_name)
void  imported_funcs_notify_schedular_state_changed (SchedularState new_state, const char *reason)
GList *  imported_funcs_config_get_avail_servers (void)
ConfigServer imported_funcs_config_get_server_info (const char *servername)
ConfigOpts  imported_funcs_config_get_opts (void)
gpointer  imported_funcs_nntp_connection_initialize (const char *servername, NNTPGrabErrCode *err)
void  imported_funcs_nntp_connection_destroy (gpointer obj)
NNTPGrabErrCode  imported_funcs_nntp_connection_get_part (gpointer obj, const char *collection_name, const NNTPFile *file, const NNTPPart *part, char **reason)
gboolean  imported_funcs_decode_file (const char *collection_name, const NNTPFile *file, int *saved_errno)
void  imported_funcs_emit_fatal_error (const char *errmsg)
void  imported_funcs_emit_part_download_complete (const char *servername, gpointer nntp_connection, const char *collection_name, const char *subject, int partnum, int size)
void  imported_funcs_emit_part_download_failed (const char *servername, gpointer nntp_connection, const char *collection_name, const char *subject, int partnum, int size, gboolean all_servers_tried)
void  imported_funcs_emit_task_moved (const char *orig_collection_name, const char *subject, const char *new_collection_name, int old_position, int new_position)
void  imported_funcs_emit_collection_moved (const char *collection_name, int old_position, int new_position)
void  imported_funcs_emit_file_download_state_update (const char *collection_name, const char *subject, int num_parts_total, int num_parts_done, int num_parts_failed, guint64 file_size, guint64 file_size_remaining, guint64 total_file_size, guint64 total_file_size_remaining)
gboolean  load_download_queue (GList **ret, char **errmsg)
gboolean  save_download_queue (GList *queue, char **errmsg)
void  free_download_queue (GList *queue)

Define Documentation

#define IS_SCHEDULAR_PLUGIN ( object   )     (G_TYPE_CHECK_INSTANCE_TYPE ((object), SCHEDULAR_PLUGIN_TYPE_OBJECT))

Definition at line 9 of file schedular_plugin.h.

#define IS_SCHEDULAR_PLUGIN_CLASS ( klass   )     (G_TYPE_CHECK_CLASS_TYPE ((klass), SCHEDULAR_PLUGIN_TYPE_OBJECT))

Definition at line 10 of file schedular_plugin.h.

#define SCHEDULAR_PLUGIN ( object   )     (G_TYPE_CHECK_INSTANCE_CAST ((object), SCHEDULAR_PLUGIN_TYPE_OBJECT, SchedularPlugin))

Definition at line 7 of file schedular_plugin.h.

#define SCHEDULAR_PLUGIN_CLASS ( klass   )     (G_TYPE_CHECK_CLASS_CAST ((klass), SCHEDULAR_PLUGIN_TYPE_OBJECT, SchedularPluginClass))

Definition at line 8 of file schedular_plugin.h.

#define SCHEDULAR_PLUGIN_GET_CLASS ( obj   )     (G_TYPE_INSTANCE_GET_CLASS ((obj), SCHEDULAR_PLUGIN_TYPE_OBJECT, SchedularPluginClass))

Definition at line 11 of file schedular_plugin.h.

#define SCHEDULAR_PLUGIN_TYPE_OBJECT   (schedular_plugin_get_type ())

Definition at line 6 of file schedular_plugin.h.


Typedef Documentation

typedef struct _decoder_data DecoderData

typedef struct _download_data DownloadData

typedef struct SchedularPlugin SchedularPlugin

Definition at line 4 of file schedular_plugin.h.


Function Documentation

void decoder_thread_func ( gpointer  data,
gpointer  user_data  
)

Definition at line 33 of file decoder_thread.c.

void download_thread_func ( gpointer  data,
gpointer  user_data  
)

Definition at line 35 of file download_thread.c.

void free_download_queue ( GList *  queue  ) 

Definition at line 723 of file queue.c.

gboolean get_next_part_to_download ( SchedularPlugin schedular,
int  server_id,
NNTPCollection **  collection,
NNTPFile **  file,
NNTPPart **  part,
GThreadPool *  poolDecoder  
)

Definition at line 138 of file plugins/schedular/schedular.c.

void imported_funcs_collection_added ( const char *  collection_name  ) 

Definition at line 58 of file imported_funcs.c.

void imported_funcs_collection_removed ( const char *  collection_name  ) 

Definition at line 64 of file imported_funcs.c.

GList* imported_funcs_config_get_avail_servers ( void   ) 

Definition at line 76 of file imported_funcs.c.

ConfigOpts imported_funcs_config_get_opts ( void   ) 

Definition at line 88 of file imported_funcs.c.

ConfigServer* imported_funcs_config_get_server_info ( const char *  servername  ) 

Definition at line 82 of file imported_funcs.c.

gboolean imported_funcs_decode_file ( const char *  collection_name,
const NNTPFile file,
int *  saved_errno  
)

Definition at line 112 of file imported_funcs.c.

void imported_funcs_emit_collection_moved ( const char *  collection_name,
int  old_position,
int  new_position  
)

Definition at line 142 of file imported_funcs.c.

void imported_funcs_emit_fatal_error ( const char *  errmsg  ) 

Definition at line 118 of file imported_funcs.c.

void imported_funcs_emit_file_download_state_update ( const char *  collection_name,
const char *  subject,
int  num_parts_total,
int  num_parts_done,
int  num_parts_failed,
guint64  file_size,
guint64  file_size_remaining,
guint64  total_file_size,
guint64  total_file_size_remaining  
)

Definition at line 148 of file imported_funcs.c.

void imported_funcs_emit_part_download_complete ( const char *  servername,
gpointer  nntp_connection,
const char *  collection_name,
const char *  subject,
int  partnum,
int  size  
)

Definition at line 124 of file imported_funcs.c.

void imported_funcs_emit_part_download_failed ( const char *  servername,
gpointer  nntp_connection,
const char *  collection_name,
const char *  subject,
int  partnum,
int  size,
gboolean  all_servers_tried  
)

Definition at line 130 of file imported_funcs.c.

void imported_funcs_emit_task_moved ( const char *  orig_collection_name,
const char *  subject,
const char *  new_collection_name,
int  old_position,
int  new_position  
)

Definition at line 136 of file imported_funcs.c.

void imported_funcs_nntp_connection_destroy ( gpointer  obj  ) 

Definition at line 100 of file imported_funcs.c.

NNTPGrabErrCode imported_funcs_nntp_connection_get_part ( gpointer  obj,
const char *  collection_name,
const NNTPFile file,
const NNTPPart part,
char **  reason  
)

Definition at line 106 of file imported_funcs.c.

gpointer imported_funcs_nntp_connection_initialize ( const char *  servername,
NNTPGrabErrCode err  
)

Definition at line 94 of file imported_funcs.c.

void imported_funcs_notify_schedular_state_changed ( SchedularState  new_state,
const char *  reason  
)

Definition at line 70 of file imported_funcs.c.

void imported_funcs_task_added ( const NNTPCollection collection,
const NNTPFile file  
)

Definition at line 40 of file imported_funcs.c.

void imported_funcs_task_removed ( const char *  collection_name,
const char *  subject,
guint64  total_file_size,
guint64  total_file_size_remaining  
)

Definition at line 46 of file imported_funcs.c.

void imported_funcs_task_state_changed ( const char *  collection_name,
const char *  subject,
TaskState  old_state,
TaskState  new_state  
)

Definition at line 52 of file imported_funcs.c.

gboolean load_download_queue ( GList **  ret,
char **  errmsg  
)

Definition at line 452 of file queue.c.

gboolean save_download_queue ( GList *  queue,
char **  errmsg  
)

Definition at line 668 of file queue.c.

GType schedular_plugin_get_type ( void   ) 

gboolean schedular_plugin_save_queue ( char **  errmsg  ) 

Definition at line 1246 of file plugins/schedular/schedular.c.

void schedular_plugin_set_imported_funcs ( PluginSchedularImportedFuncs  funcs  ) 

Definition at line 34 of file imported_funcs.c.

void stop_schedular_from_seperate_thread ( const char *  reason  ) 

Definition at line 516 of file plugins/schedular/schedular.c.

void update_part_download_status ( NNTPCollection collection,
NNTPFile file,
NNTPPart part,
int  server_id,
gboolean  success,
gboolean  reset_to_zero,
gboolean  queue_is_being_paused,
gboolean  dont_retry_anymore,
gpointer  nntpconnection  
)

Definition at line 390 of file plugins/schedular/schedular.c.


Generated on Sun Oct 12 01:45:31 2008 for NNTPGrab by  1.5.4