-extern void del_invite(aClient *cptr, aChannel *chptr);
-extern void list_next_channels(aClient *cptr, int nr);
-extern int m_join(aClient *cptr, aClient *sptr, int parc, char *parv[]);
-extern int m_create(aClient *cptr, aClient *sptr, int parc, char *parv[]);
-extern int m_destruct(aClient *cptr, aClient *sptr, int parc, char *parv[]);
-extern int m_burst(aClient *cptr, aClient *sptr, int parc, char *parv[]);
-extern int m_part(aClient *cptr, aClient *sptr, int parc, char *parv[]);
-extern int m_kick(aClient *cptr, aClient *sptr, int parc, char *parv[]);
-extern int m_topic(aClient *cptr, aClient *sptr, int parc, char *parv[]);
-extern int m_invite(aClient *cptr, aClient *sptr, int parc, char *parv[]);
-extern int m_list(aClient *cptr, aClient *sptr, int parc, char *parv[]);
-extern void send_user_joins(aClient *cptr, aClient *user);
-
-extern aChannel *channel;
-
-#endif /* CHANNEL_H */
+extern void del_invite(struct Client *cptr, struct Channel *chptr);
+extern void list_set_default(void); /* this belongs elsewhere! */
+
+extern void RevealDelayedJoin(struct Membership *member);
+extern void CheckDelayedJoins(struct Channel *chan);
+
+extern void modebuf_init(struct ModeBuf *mbuf, struct Client *source,
+ struct Client *connect, struct Channel *chan,
+ unsigned int dest);
+extern void modebuf_mode(struct ModeBuf *mbuf, unsigned int mode);
+extern void modebuf_mode_uint(struct ModeBuf *mbuf, unsigned int mode,
+ unsigned int uint);
+extern void modebuf_mode_string(struct ModeBuf *mbuf, unsigned int mode,
+ char *string, int free);
+extern void modebuf_mode_client(struct ModeBuf *mbuf, unsigned int mode,
+ struct Client *client, int oplevel);
+extern int modebuf_flush(struct ModeBuf *mbuf);
+extern void modebuf_extract(struct ModeBuf *mbuf, char *buf);
+
+extern void mode_ban_invalidate(struct Channel *chan);
+extern void mode_invite_clear(struct Channel *chan);
+
+extern int mode_parse(struct ModeBuf *mbuf, struct Client *cptr,
+ struct Client *sptr, struct Channel *chptr,
+ int parc, char *parv[], unsigned int flags,
+ struct Membership* member);
+
+#define MODE_PARSE_SET 0x01 /**< actually set channel modes */
+#define MODE_PARSE_STRICT 0x02 /**< +m +n +t style not supported */
+#define MODE_PARSE_FORCE 0x04 /**< force the mode to be applied */
+#define MODE_PARSE_BOUNCE 0x08 /**< we will be bouncing the modes */
+#define MODE_PARSE_NOTOPER 0x10 /**< send "not chanop" to user */
+#define MODE_PARSE_NOTMEMBER 0x20 /**< send "not member" to user */
+#define MODE_PARSE_WIPEOUT 0x40 /**< wipe out +k and +l during burst */
+#define MODE_PARSE_BURST 0x80 /**< be even more strict w/extra args */
+
+extern void joinbuf_init(struct JoinBuf *jbuf, struct Client *source,
+ struct Client *connect, unsigned int type,
+ char *comment, time_t create);
+extern void joinbuf_join(struct JoinBuf *jbuf, struct Channel *chan,
+ unsigned int flags);
+extern int joinbuf_flush(struct JoinBuf *jbuf);
+extern struct Ban *make_ban(const char *banstr);
+extern struct Ban *find_ban(struct Client *cptr, struct Ban *banlist);
+extern int apply_ban(struct Ban **banlist, struct Ban *newban, int free);
+extern void free_ban(struct Ban *ban);
+
+#endif /* INCLUDED_channel_h */