matcher grammar: in condition, "execute" is changed to "test" (solve a bug)
[claws.git] / src / matcher.h
index ba2cbcaa0bc341d482410da71d85790c16102ede..9c1978472118ef58ba1d6c766f26ea2d9816c5a9 100644 (file)
@@ -93,7 +93,7 @@ enum {
        MC_(HEADERS_PART), MC_(NOT_HEADERS_PART),
        MC_(MESSAGE), MC_(NOT_MESSAGE),
        MC_(BODY_PART), MC_(NOT_BODY_PART),
-       MC_(EXECUTE), MC_(NOT_EXECUTE),
+       MC_(TEST), MC_(NOT_TEST),
        MC_(SCORE_EQUAL),
        MC_(SIZE_GREATER), 
        MC_(SIZE_SMALLER),
@@ -111,36 +111,38 @@ enum {
        MA_(DELETE),
        MA_(MARK),
        MA_(UNMARK),
+       MA_(LOCK),
+       MA_(UNLOCK),
        MA_(MARK_AS_READ),
        MA_(MARK_AS_UNREAD),
        MA_(FORWARD),
        MA_(FORWARD_AS_ATTACHMENT),
        MA_(COLOR),
        MA_(REDIRECT),
-       MA_(DELETE_ON_SERVER),
+       MA_(CHANGE_SCORE),
        /* boolean operations */
        MB_(OR),
        MB_(AND)
 };
 
-gchar *get_matchparser_tab_str         (gint id);
+const gchar *get_matchparser_tab_str   (gint id);
 gint get_matchparser_tab_id            (const gchar *str); 
 
-MatcherProp *matcherprop_new           (gint    criteria, 
-                                        gchar  *header,
-                                        gint    matchtype, 
-                                        gchar  *expr,
-                                        int     age);
-MatcherProp *matcherprop_unquote_new   (gint    criteria, 
-                                        gchar  *header,
-                                        gint    matchtype, 
-                                        gchar  *expr,
-                                        int     value);
+MatcherProp *matcherprop_new           (gint            criteria, 
+                                        const gchar    *header,
+                                        gint            matchtype, 
+                                        const gchar    *expr,
+                                        int             value);
+MatcherProp *matcherprop_unquote_new   (gint            criteria, 
+                                        const gchar    *header,
+                                        gint            matchtype, 
+                                        const gchar    *expr,
+                                        int             value);
 void matcherprop_free                  (MatcherProp *prop);
 
 MatcherProp *matcherprop_parse         (gchar  **str);
 
-MatcherProp *matcherprop_copy          (MatcherProp *src);
+MatcherProp *matcherprop_copy          (const MatcherProp *src);
 
 gboolean matcherprop_match             (MatcherProp    *prop, 
                                         MsgInfo        *info);
@@ -162,11 +164,12 @@ gchar *matcher_parse_str          (gchar          **str);
 gchar *matcher_escape_str              (const gchar    *str);
 gchar *matcher_unescape_str            (gchar          *str);
 gchar *matcherprop_to_string           (MatcherProp    *matcher);
-gchar *matcherlist_to_string           (MatcherList    *matchers);
-gchar *matching_build_command          (gchar          *cmd, 
+gchar *matcherlist_to_string           (const MatcherList      *matchers);
+gchar *matching_build_command          (const gchar    *cmd, 
                                         MsgInfo        *info);
 
 void prefs_matcher_read_config         (void);
 void prefs_matcher_write_config                (void);
+void *matcher_parser_scan_string        (gchar          *str);
 
 #endif