2602e34c1b87d3be9bf88e3b8a38cae78899ace4
[claws.git] / src / scoring.h
1 #ifndef SCORING_H
2
3 #define SCORING_H
4
5 #include <glib.h>
6 #include "matcher.h"
7 #include "procmsg.h"
8
9 #define MAX_SCORE 9999
10 #define MIN_SCORE -9999
11
12 struct _ScoringProp {
13         MatcherList * matchers;
14         int score;
15 };
16
17 typedef struct _ScoringProp ScoringProp;
18
19 extern GSList * prefs_scoring;
20
21
22 ScoringProp * scoringprop_new(MatcherList * matchers, int score);
23 void scoringprop_free(ScoringProp * prop);
24 gint scoringprop_score_message(ScoringProp * scoring, MsgInfo * info);
25
26 ScoringProp * scoringprop_parse(gchar ** str);
27
28
29 gint score_message(GSList * scoring_list, MsgInfo * info);
30
31 void prefs_scoring_write_config(void);
32 void prefs_scoring_read_config(void);
33 gchar * scoringprop_to_string(ScoringProp * prop);
34
35 #endif