6 #define TABLE_FLAG_USE_POINTER 0x01
7 #define TABLE_FLAG_COL_BOLD 0x02
8 #define TABLE_FLAG_COL_CONTENTS 0x04
24 char **table_lines; //we just store this to free it in table_free
28 struct ClientSocket *client;
29 struct ChanNode *chan;
30 char addModes[MAXMODES];
31 char delModes[MAXMODES];
32 char *addModesParams[MAXMODES];
33 char *delModesParams[MAXMODES];
38 int match(const char *mask, const char *name);
40 struct Table *table_init(int width, int length, int flags);
41 int table_add(struct Table *table, char **entry);
42 int table_change(struct Table *table, int row, char **entry);
43 int table_change_field(struct Table *table, int row, int col, char *entry);
44 int table_set_bold(struct Table *table, int collum, int bold);
45 char **table_end(struct Table *table);
46 void table_free(struct Table *table);
48 char* timeToStr(struct UserNode *user, int seconds, int items, char *buf);
49 int strToTime(struct UserNode *user, char *str);
51 struct ModeBuffer* initModeBuffer(struct ClientSocket *client, struct ChanNode *chan);
52 #define modeBufferSimpleMode(MODEBUF,ADD,MODE) modeBufferSet(MODEBUF, ADD, MODE, NULL)
53 #define modeBufferOp(MODEBUF,USER) modeBufferSet(MODEBUF, 1, 'o', USER)
54 #define modeBufferDeop(MODEBUF,USER) modeBufferSet(MODEBUF, 0, 'o', USER)
55 #define modeBufferVoice(MODEBUF,USER) modeBufferSet(MODEBUF, 1, 'v', USER)
56 #define modeBufferDevoice(MODEBUF,USER) modeBufferSet(MODEBUF, 0, 'v', USER)
57 #define modeBufferBan(MODEBUF,MASK) modeBufferSet(MODEBUF, 1, 'b', MASK)
58 #define modeBufferUnban(MODEBUF,MASK) modeBufferSet(MODEBUF, 0, 'b', MASK)
59 void modeBufferSet(struct ModeBuffer *modeBuf, int add, char mode, char *param);
60 void flushModeBuffer(struct ModeBuffer *modeBuf);
61 void freeModeBuffer(struct ModeBuffer *modeBuf);
63 int is_ircmask(const char *text);
65 char* generate_banmask(struct UserNode *user, char *buffer);
66 char* make_banmask(char *input, char* buffer);
67 int isFakeHost(char *host);