## camel-junk-plugin

camel-junk-plugin

## Synopsis

    #define             CAMEL_JUNK_PLUGIN                   (x)
                        CamelJunkPlugin;
    const char *        camel_junk_plugin_get_name          (CamelJunkPlugin *csp);
    int                 camel_junk_plugin_check_junk        (CamelJunkPlugin *csp,
                                                             struct _CamelMimeMessage *message);
    void                camel_junk_plugin_report_junk       (CamelJunkPlugin *csp,
                                                             struct _CamelMimeMessage *message);
    void                camel_junk_plugin_report_notjunk    (CamelJunkPlugin *csp,
                                                             struct _CamelMimeMessage *message);
    void                camel_junk_plugin_commit_reports    (CamelJunkPlugin *csp);
    void                camel_junk_plugin_init              (CamelJunkPlugin *csp);

## Description

## Details

### CAMEL_JUNK_PLUGIN()

    #define CAMEL_JUNK_PLUGIN(x) ((CamelJunkPlugin *) x)

`x` : |

### CamelJunkPlugin

    typedef struct {
    	/* junk filter human readable name, translated */
    	const char * (*get_name) (struct _CamelJunkPlugin *csp);

    	/* should be set to 1 */
    	int api_version;

    	/* when called, it should return TRUE if message is identified as junk,
    	   FALSE otherwise */
    	int (*check_junk) (struct _CamelJunkPlugin *csp, struct _CamelMimeMessage *message);

    	/* called when user identified a message to be junk */
    	void (*report_junk) (struct _CamelJunkPlugin *csp, struct _CamelMimeMessage *message);

    	/* called when user identified a message not to be junk */
    	void (*report_notjunk) (struct _CamelJunkPlugin *csp, struct _CamelMimeMessage *message);

    	/* called after one or more junk/ham(s) reported */
    	void (*commit_reports) (struct _CamelJunkPlugin *csp);

    	/* called before all other calls to junk plugin for initialization */
    	void (*init) (struct _CamelJunkPlugin *csp);
    } CamelJunkPlugin;

### camel_junk_plugin_get_name ()

    const char *        camel_junk_plugin_get_name          (CamelJunkPlugin *csp);

`csp` : |
Returns : |

### camel_junk_plugin_check_junk ()

    int                 camel_junk_plugin_check_junk        (CamelJunkPlugin *csp,
                                                             struct _CamelMimeMessage *message);

`csp` : |
`message` : |
Returns : |

### camel_junk_plugin_report_junk ()

    void                camel_junk_plugin_report_junk       (CamelJunkPlugin *csp,
                                                             struct _CamelMimeMessage *message);

`csp` : |
`message` : |

### camel_junk_plugin_report_notjunk ()

    void                camel_junk_plugin_report_notjunk    (CamelJunkPlugin *csp,
                                                             struct _CamelMimeMessage *message);

`csp` : |
`message` : |

### camel_junk_plugin_commit_reports ()

    void                camel_junk_plugin_commit_reports    (CamelJunkPlugin *csp);

`csp` : |

### camel_junk_plugin_init ()

    void                camel_junk_plugin_init              (CamelJunkPlugin *csp);

`csp` : |