From 32592987c8f5c2edf347d2312b426ed5c3170e6f Mon Sep 17 00:00:00 2001 From: Adam Date: Tue, 19 Feb 2013 03:58:54 -0500 Subject: Allow /os mode clear [all] to unset modes, similar to old clearmodes --- include/channels.h | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) (limited to 'include') diff --git a/include/channels.h b/include/channels.h index 06132a32f..3cf337e65 100644 --- a/include/channels.h +++ b/include/channels.h @@ -142,12 +142,6 @@ class CoreExport Channel : public Base, public Extensible */ size_t HasMode(const Anope::string &name, const Anope::string ¶m = ""); - /** Get a list of modes on a channel - * @param name A mode name to get the list of - * @return a pair of iterators for the beginning and end of the list - */ - std::pair GetModeList(const Anope::string &name); - /** Set a mode internally on a channel, this is not sent out to the IRCd * @param setter The setter * @param cm The mode @@ -241,6 +235,17 @@ class CoreExport Channel : public Base, public Extensible */ bool Kick(BotInfo *bi, User *u, const char *reason = NULL, ...); + /** Get all modes set on this channel, excluding status modes. + * @return a map of modes and their optional parameters. + */ + const ModeList &GetModes() const; + + /** Get a list of modes on a channel + * @param name A mode name to get the list of + * @return a pair of iterators for the beginning and end of the list + */ + std::pair GetModeList(const Anope::string &name); + /** Get a string of the modes set on this channel * @param complete Include mode parameters * @param plus If set to false (with complete), mode parameters will not be given for modes requring no parameters to be unset -- cgit