Fix wrong typename escapes to prevent doxygen auto-linking (& -> %).
[ircu2.10.12-pk.git] / include / match.h
1 /*
2  * match.h
3  */
4 /* @file
5  * @brief Interface for matching strings to IRC masks.
6  * @version $Id$
7  */
8 #ifndef INCLUDED_match_h
9 #define INCLUDED_match_h
10 #ifndef INCLUDED_sys_types_h
11 #include <sys/types.h>         /* XXX - broken BSD system headers */
12 #define INCLUDED_sys_types_h
13 #endif
14 #ifndef INCLUDED_res_h
15 #include "res.h"
16 #endif
17
18 /*
19  * Prototypes
20  */
21
22 /*
23  * XXX - match returns 0 if a match is found. Smelly interface
24  * needs to be fixed. --Bleep
25  */
26 extern int mmatch(const char *old_mask, const char *new_mask);
27 extern int match(const char *ma, const char *na);
28 extern char *collapse(char *pattern);
29
30 extern int matchcomp(char *cmask, int *minlen, int *charset, const char *mask);
31 extern int matchexec(const char *string, const char *cmask, int minlen);
32 extern int matchdecomp(char *mask, const char *cmask);
33 extern int mmexec(const char *wcm, int wminlen, const char *rcm, int rminlen);
34
35 extern int check_if_ipmask(const char *mask);
36 extern int ipmask_parse(const char *in, struct irc_in_addr *mask, unsigned char *bits_ptr);
37 extern int ipmask_check(const struct irc_in_addr *addr, const struct irc_in_addr *mask, unsigned char bits);
38
39 #endif /* INCLUDED_match_h */