diff options
author | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2009-02-05 19:48:07 +0300 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2009-02-05 19:48:07 +0300 |
commit | bf6f2838403722ea571daaeec5981831313d474b (patch) | |
tree | 25fe553ce04b9f724537364c44889a7d326566b7 /src/message.h | |
parent | 32a96e82d075bdba6e9e567080977a76830cbce2 (diff) | |
download | rspamd-bf6f2838403722ea571daaeec5981831313d474b.tar.gz rspamd-bf6f2838403722ea571daaeec5981831313d474b.zip |
* Add some comments and documentation
Diffstat (limited to 'src/message.h')
-rw-r--r-- | src/message.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/message.h b/src/message.h index 106b32559..7b880f226 100644 --- a/src/message.h +++ b/src/message.h @@ -25,14 +25,38 @@ #include <gmime/gmime.h> +/** + * Message processing functions and structures + */ + struct mime_part { GMimeContentType *type; GByteArray *content; TAILQ_ENTRY (mime_part) next; }; +/** + * Process message with all filters/statfiles, extract mime parts, urls and + * call metrics consolidation functions + * @param task worker_task object + * @return 0 if we have delayed filters to process and 1 if we have finished with processing + */ int process_message (struct worker_task *task); + +/* + * Process message for learning statfile classifier. + * It extract text and html parts and strip tags from html parts + * @param session session that contains message + * @return 0 allways (may be changed in future) + */ int process_learn (struct controller_session *session); + +/** + * Return next text part (or html with stripped tags) for specified list + * @param pool memory pool in which place object + * @param parts current position in list + * @param cur pointer to which we save current position after processing + */ GByteArray* get_next_text_part (memory_pool_t *pool, GList *parts, GList **cur); #endif |