Fix a typo
[privoxy.git] / actions.h
1 #ifndef ACTIONS_H_INCLUDED
2 #define ACTIONS_H_INCLUDED
3 #define ACTIONS_H_VERSION "$Id: actions.h,v 1.20 2011/09/04 11:10:56 fabiankeil Exp $"
4 /*********************************************************************
5  *
6  * File        :  $Source: /cvsroot/ijbswa/current/actions.h,v $
7  *
8  * Purpose     :  Declares functions to work with actions files
9  *                Functions declared include: FIXME
10  *
11  * Copyright   :  Written by and Copyright (C) 2001-2007 the SourceForge
12  *                Privoxy team. http://www.privoxy.org/
13  *
14  *                Based on the Internet Junkbuster originally written
15  *                by and Copyright (C) 1997 Anonymous Coders and
16  *                Junkbusters Corporation.  http://www.junkbusters.com
17  *
18  *                This program is free software; you can redistribute it
19  *                and/or modify it under the terms of the GNU General
20  *                Public License as published by the Free Software
21  *                Foundation; either version 2 of the License, or (at
22  *                your option) any later version.
23  *
24  *                This program is distributed in the hope that it will
25  *                be useful, but WITHOUT ANY WARRANTY; without even the
26  *                implied warranty of MERCHANTABILITY or FITNESS FOR A
27  *                PARTICULAR PURPOSE.  See the GNU General Public
28  *                License for more details.
29  *
30  *                The GNU General Public License should be included with
31  *                this file.  If not, you can view it at
32  *                http://www.gnu.org/copyleft/gpl.html
33  *                or write to the Free Software Foundation, Inc., 59
34  *                Temple Place - Suite 330, Boston, MA  02111-1307, USA.
35  *
36  *********************************************************************/
37
38
39 #ifdef __cplusplus
40 extern "C" {
41 #endif
42
43
44 struct action_spec;
45 struct current_action_spec;
46 struct client_state;
47
48
49
50 /* This structure is used to hold user-defined aliases */
51 struct action_alias
52 {
53    const char * name;
54    struct action_spec action[1];
55    struct action_alias * next;
56 };
57
58
59 extern jb_err get_actions (char *line,
60                            struct action_alias * alias_list,
61                            struct action_spec *cur_action);
62 extern void free_alias_list(struct action_alias *alias_list);
63
64 extern void init_action(struct action_spec *dest);
65 extern void free_action(struct action_spec *src);
66 extern jb_err merge_actions (struct action_spec *dest,
67                              const struct action_spec *src);
68 #if 0
69 extern int update_action_bits_for_all_tags(struct client_state *csp);
70 #endif
71 extern int update_action_bits_for_tag(struct client_state *csp, const char *tag);
72 extern jb_err copy_action (struct action_spec *dest,
73                            const struct action_spec *src);
74 extern char * actions_to_text     (const struct action_spec *action);
75 extern char * actions_to_html     (const struct client_state *csp,
76                                    const struct action_spec *action);
77 extern void init_current_action     (struct current_action_spec *dest);
78 extern void free_current_action     (struct current_action_spec *src);
79 extern jb_err merge_current_action  (struct current_action_spec *dest,
80                                      const struct action_spec *src);
81 extern char * current_action_to_html(const struct client_state *csp,
82                                      const struct current_action_spec *action);
83 extern char * actions_to_line_of_text(const struct current_action_spec *action);
84
85 extern jb_err get_action_token(char **line, char **name, char **value);
86 extern void unload_actions_file(void *file_data);
87 extern int load_action_files(struct client_state *csp);
88
89 #ifdef FEATURE_GRACEFUL_TERMINATION
90 void unload_current_actions_file(void);
91 #endif
92
93
94 /* Revision control strings from this header and associated .c file */
95 extern const char actions_rcs[];
96 extern const char actions_h_rcs[];
97
98 #ifdef __cplusplus
99 } /* extern "C" */
100 #endif
101
102 #endif /* ndef ACTIONS_H_INCLUDED */
103
104 /*
105   Local Variables:
106   tab-width: 3
107   end:
108 */
109