summaryrefslogtreecommitdiff
path: root/nick.h
blob: 3ba1e3dc7053ecd226a3930959fefa7b18b2b050 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#ifndef _NICK_H_
#define _NICK_H_

#include <pcre.h>

struct nick_t {
	char *name;
	struct nick_regex_t {
		pcre *re;
		pcre_extra *re_e;
		struct nick_regex_t *next;
	} *regexes;
	struct nick_t *next;
};

void nick_init();
struct nick_t *nick_add(const char *name);
int nick_regex_add(struct nick_t *nick, const char *re_s);
char *nick_get(char *name);
void nick_free();

#endif