diff -r 8065a624ba37 -r 94e6c3b4230f src/modules/logwatch.h --- a/src/modules/logwatch.h Sat Apr 11 04:26:22 2009 +0300 +++ b/src/modules/logwatch.h Sat Apr 11 04:26:46 2009 +0300 @@ -65,6 +65,16 @@ }; /** + * Maximum number of capture groups in the filter's regexp + */ +#define LOGWATCH_FILTER_GROUPS_MAX 16 + +/** + * Maximum length of output string, not including NUL byte + */ +#define LOGWATCH_FILTER_OUT_MAX 450 + +/** * A channel for outputting logwatch output * * XXX; do we need this? @@ -129,3 +139,13 @@ */ void logwatch_filter_destroy (struct logwatch_filter *filter); +/** + * Pass the given line (from the given source) through the given filter + */ +err_t logwatch_filter_apply (const struct logwatch_filter *filter, const struct logwatch_source *source, const char *line, struct error_info *err); + +/** + * Handle a line from the given source by applying it to all filters + */ +void logwatch_on_line (struct logwatch *ctx, const struct logwatch_source *source, const char *line); +