diff options
author | Sadie Powell <sadie@witchery.services> | 2024-01-23 15:28:23 +0000 |
---|---|---|
committer | Sadie Powell <sadie@witchery.services> | 2024-01-23 15:28:23 +0000 |
commit | a6a0f6c44780c839b2269f4f29a26ecfdbd95544 (patch) | |
tree | d4d1fded5c14350eb003a665ca8de500a0440cea | |
parent | 398d674cf40c0dba4e4cd2edd0f325ace15128c2 (diff) |
Improve the layout of types that inherit from another type.
232 files changed, 1648 insertions, 798 deletions
diff --git a/include/access.h b/include/access.h index 4a20a8c90..4242509aa 100644 --- a/include/access.h +++ b/include/access.h @@ -52,7 +52,8 @@ public: /* A provider of access. Only used for creating ChanAccesses, as * they contain pure virtual functions. */ -class CoreExport AccessProvider : public Service +class CoreExport AccessProvider + : public Service { public: AccessProvider(Module *owner, const Anope::string &name); @@ -70,7 +71,8 @@ public: }; /* Represents one entry of an access list on a channel. */ -class CoreExport ChanAccess : public Serializable +class CoreExport ChanAccess + : public Serializable { Anope::string mask; /* account this access entry is for, if any */ diff --git a/include/account.h b/include/account.h index 160b0a260..1062b67bf 100644 --- a/include/account.h +++ b/include/account.h @@ -28,7 +28,9 @@ extern CoreExport nickcoreid_map NickCoreIdList; /* A registered nickname. * It matters that Base is here before Extensible (it is inherited by Serializable) */ -class CoreExport NickAlias : public Serializable, public Extensible +class CoreExport NickAlias + : public Serializable + , public Extensible { Anope::string vhost_ident, vhost_host, vhost_creator; time_t vhost_created; @@ -104,7 +106,9 @@ public: * account's display. * It matters that Base is here before Extensible (it is inherited by Serializable) */ -class CoreExport NickCore : public Serializable, public Extensible +class CoreExport NickCore + : public Serializable + , public Extensible { /* Channels which reference this core in some way (this is on their access list, akick list, is founder, successor, etc) */ Serialize::Checker<std::map<ChannelInfo *, int> > chanaccess; diff --git a/include/anope.h b/include/anope.h index fc8d01fba..976c69702 100644 --- a/include/anope.h +++ b/include/anope.h @@ -628,7 +628,8 @@ public: /** A derived form of sepstream, which separates on commas */ -class commasepstream : public sepstream +class commasepstream + : public sepstream { public: /** Initialize with comma separator @@ -638,7 +639,8 @@ public: /** A derived form of sepstream, which separates on spaces */ -class spacesepstream : public sepstream +class spacesepstream + : public sepstream { public: /** Initialize with space separator @@ -652,7 +654,8 @@ public: * be loaded. If this happens, the error message returned by ModuleException::GetReason will be displayed to the user * attempting to load the module, or dumped to the console if the ircd is currently loading for the first time. */ -class CoreExport CoreException : public std::exception +class CoreExport CoreException + : public std::exception { protected: /** Holds the error message to be displayed @@ -691,7 +694,8 @@ public: } }; -class CoreExport ModuleException : public CoreException +class CoreExport ModuleException + : public CoreException { public: /** Default constructor, just uses the error message 'Module threw an exception'. @@ -708,7 +712,8 @@ public: virtual ~ModuleException() noexcept = default; }; -class CoreExport ConvertException : public CoreException +class CoreExport ConvertException + : public CoreException { public: ConvertException(const Anope::string &reason = "") : CoreException(reason) { } diff --git a/include/base.h b/include/base.h index 99b16fed7..07b3bdf89 100644 --- a/include/base.h +++ b/include/base.h @@ -43,7 +43,8 @@ public: * no longer be valid once the object it refers is destructed. */ template<typename T> -class Reference : public ReferenceBase +class Reference + : public ReferenceBase { protected: T *ref = nullptr; diff --git a/include/bots.h b/include/bots.h index 68bfd9318..35ec7cd50 100644 --- a/include/bots.h +++ b/include/bots.h @@ -19,7 +19,9 @@ typedef Anope::map<BotInfo *> botinfo_map; extern CoreExport Serialize::Checker<botinfo_map> BotListByNick, BotListByUID; /* A service bot (NickServ, ChanServ, a BotServ bot, etc). */ -class CoreExport BotInfo : public User, public Serializable +class CoreExport BotInfo + : public User + , public Serializable { /* Channels this bot is assigned to */ Serialize::Checker<std::set<ChannelInfo *> > channels; diff --git a/include/channels.h b/include/channels.h index 1e7531ab2..0230cc566 100644 --- a/include/channels.h +++ b/include/channels.h @@ -18,7 +18,8 @@ typedef Anope::hash_map<Channel *> channel_map; extern CoreExport channel_map ChannelList; /* A user container, there is one of these per user per channel. */ -struct ChanUserContainer : public Extensible +struct ChanUserContainer + : public Extensible { User *user; Channel *chan; @@ -28,7 +29,9 @@ struct ChanUserContainer : public Extensible ChanUserContainer(User *u, Channel *c) : user(u), chan(c) { } }; -class CoreExport Channel : public Base, public Extensible +class CoreExport Channel + : public Base + , public Extensible { static std::vector<Channel *> deleting; diff --git a/include/commands.h b/include/commands.h index cb53cf017..5f15da345 100644 --- a/include/commands.h +++ b/include/commands.h @@ -88,7 +88,8 @@ public: /** Every services command is a class, inheriting from Command. */ -class CoreExport Command : public Service +class CoreExport Command + : public Service { Anope::string desc; std::vector<Anope::string> syntax; diff --git a/include/config.h b/include/config.h index 7a032d7e9..cb8de7c55 100644 --- a/include/config.h +++ b/include/config.h @@ -98,7 +98,8 @@ namespace Configuration struct Uplink; - struct CoreExport Conf : Block + struct CoreExport Conf + : Block { /* options:readtimeout */ time_t ReadTimeout; @@ -171,7 +172,8 @@ namespace Configuration * be loaded. If this happens, the error message returned by ModuleException::GetReason will be displayed to the user * attempting to load the module, or dumped to the console if the ircd is currently loading for the first time. */ -class CoreExport ConfigException : public CoreException +class CoreExport ConfigException + : public CoreException { public: /** Default constructor, just uses the error message 'Config threw an exception'. diff --git a/include/extensible.h b/include/extensible.h index 7388651d8..a83d9e81f 100644 --- a/include/extensible.h +++ b/include/extensible.h @@ -15,7 +15,8 @@ class Extensible; -class CoreExport ExtensibleBase : public Service +class CoreExport ExtensibleBase + : public Service { protected: std::map<Extensible *, void *> items; @@ -53,7 +54,8 @@ public: }; template<typename T> -class BaseExtensibleItem : public ExtensibleBase +class BaseExtensibleItem + : public ExtensibleBase { protected: virtual T *Create(Extensible *) = 0; @@ -124,7 +126,8 @@ public: }; template<typename T> -class ExtensibleItem : public BaseExtensibleItem<T> +class ExtensibleItem + : public BaseExtensibleItem<T> { protected: T* Create(Extensible *obj) override @@ -136,7 +139,8 @@ public: }; template<typename T> -class PrimitiveExtensibleItem : public BaseExtensibleItem<T> +class PrimitiveExtensibleItem + : public BaseExtensibleItem<T> { protected: T* Create(Extensible *obj) override @@ -160,7 +164,8 @@ public: }; template<typename T> -class SerializableExtensibleItem : public PrimitiveExtensibleItem<T> +class SerializableExtensibleItem + : public PrimitiveExtensibleItem<T> { public: SerializableExtensibleItem(Module *m, const Anope::string &n) : PrimitiveExtensibleItem<T>(m, n) { } @@ -204,7 +209,8 @@ public: }; template<typename T> -struct ExtensibleRef : ServiceReference<BaseExtensibleItem<T> > +struct ExtensibleRef + : ServiceReference<BaseExtensibleItem<T> > { ExtensibleRef(const Anope::string &n) : ServiceReference<BaseExtensibleItem<T> >("Extensible", n) { } }; diff --git a/include/hashcomp.h b/include/hashcomp.h index 13dc3ca10..91ccc3391 100644 --- a/include/hashcomp.h +++ b/include/hashcomp.h @@ -27,7 +27,8 @@ namespace Anope /* ASCII case insensitive ctype. */ template<typename char_type> - class ascii_ctype : public std::ctype<char_type> + class ascii_ctype + : public std::ctype<char_type> { public: char_type do_toupper(char_type c) const override @@ -49,7 +50,8 @@ namespace Anope /* rfc1459 case insensitive ctype, { = [, } = ], and | = \ */ template<typename char_type> - class rfc1459_ctype : public ascii_ctype<char_type> + class rfc1459_ctype + : public ascii_ctype<char_type> { public: char_type do_toupper(char_type c) const override @@ -78,7 +80,8 @@ namespace ci * This class is used to implement ci::string, a case-insensitive, ASCII- * comparing string class. */ - struct CoreExport ci_char_traits : std::char_traits<char> + struct CoreExport ci_char_traits + : std::char_traits<char> { /** Check if two chars match. * @param c1st First character diff --git a/include/mail.h b/include/mail.h index f0bb6d10d..1a0ce88cc 100644 --- a/include/mail.h +++ b/include/mail.h @@ -22,7 +22,8 @@ namespace Mail extern CoreExport bool Validate(const Anope::string &email); /* A email message being sent */ - class Message : public Thread + class Message + : public Thread { private: Anope::string sendmail_path; diff --git a/include/memo.h b/include/memo.h index 0eac6859e..5e7c1a5c9 100644 --- a/include/memo.h +++ b/include/memo.h @@ -14,7 +14,8 @@ #include "anope.h" #include "serialize.h" -class CoreExport Memo : public Serializable +class CoreExport Memo + : public Serializable { public: MemoInfo *mi; diff --git a/include/messages.h b/include/messages.h index 7782aa665..206570940 100644 --- a/include/messages.h +++ b/include/messages.h @@ -21,35 +21,40 @@ namespace Message { - struct CoreExport Away : IRCDMessage + struct CoreExport Away + : IRCDMessage { Away(Module *creator, const Anope::string &mname = "AWAY") : IRCDMessage(creator, mname, 0) { SetFlag(IRCDMESSAGE_REQUIRE_USER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Capab : IRCDMessage + struct CoreExport Capab + : IRCDMessage { Capab(Module *creator, const Anope::string &mname = "CAPAB") : IRCDMessage(creator, mname, 1) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Error : IRCDMessage + struct CoreExport Error + : IRCDMessage { Error(Module *creator, const Anope::string &mname = "ERROR") : IRCDMessage(creator, mname, 1) { } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Invite : IRCDMessage + struct CoreExport Invite + : IRCDMessage { Invite(Module *creator, const Anope::string &mname = "INVITE") : IRCDMessage(creator, mname, 2) { SetFlag(IRCDMESSAGE_REQUIRE_USER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Join : IRCDMessage + struct CoreExport Join + : IRCDMessage { Join(Module *creator, const Anope::string &mname = "JOIN") : IRCDMessage(creator, mname, 1) { SetFlag(IRCDMESSAGE_REQUIRE_USER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -67,105 +72,120 @@ namespace Message static void SJoin(MessageSource &source, const Anope::string &chan, time_t ts, const Anope::string &modes, const std::list<SJoinUser> &users); }; - struct CoreExport Kick : IRCDMessage + struct CoreExport Kick + : IRCDMessage { Kick(Module *creator, const Anope::string &mname = "KICK") : IRCDMessage(creator, mname, 2) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Kill : IRCDMessage + struct CoreExport Kill + : IRCDMessage { Kill(Module *creator, const Anope::string &mname = "KILL") : IRCDMessage(creator, mname, 2) { } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Mode : IRCDMessage + struct CoreExport Mode + : IRCDMessage { Mode(Module *creator, const Anope::string &mname = "MODE") : IRCDMessage(creator, mname, 2) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport MOTD : IRCDMessage + struct CoreExport MOTD + : IRCDMessage { MOTD(Module *creator, const Anope::string &mname = "MOTD") : IRCDMessage(creator, mname, 1) { } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Notice : IRCDMessage + struct CoreExport Notice + : IRCDMessage { Notice(Module *creator, const Anope::string &mname = "NOTICE") : IRCDMessage(creator, mname, 2) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Part : IRCDMessage + struct CoreExport Part + : IRCDMessage { Part(Module *creator, const Anope::string &mname = "PART") : IRCDMessage(creator, mname, 1) { SetFlag(IRCDMESSAGE_REQUIRE_USER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Ping : IRCDMessage + struct CoreExport Ping + : IRCDMessage { Ping(Module *creator, const Anope::string &mname = "PING") : IRCDMessage(creator, mname, 1) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Privmsg : IRCDMessage + struct CoreExport Privmsg + : IRCDMessage { Privmsg(Module *creator, const Anope::string &mname = "PRIVMSG") : IRCDMessage(creator, mname, 2) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Quit : IRCDMessage + struct CoreExport Quit + : IRCDMessage { Quit(Module *creator, const Anope::string &mname = "QUIT") : IRCDMessage(creator, mname, 1) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport SQuit : IRCDMessage + struct CoreExport SQuit + : IRCDMessage { SQuit(Module *creator, const Anope::string &mname = "SQUIT") : IRCDMessage(creator, mname, 2) { } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Stats : IRCDMessage + struct CoreExport Stats + : IRCDMessage { Stats(Module *creator, const Anope::string &mname = "STATS") : IRCDMessage(creator, mname, 1) { SetFlag(IRCDMESSAGE_REQUIRE_USER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Time : IRCDMessage + struct CoreExport Time + : IRCDMessage { Time(Module *creator, const Anope::string &mname = "TIME") : IRCDMessage(creator, mname, 0) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Topic : IRCDMessage + struct CoreExport Topic + : IRCDMessage { Topic(Module *creator, const Anope::string &mname = "TOPIC") : IRCDMessage(creator, mname, 2) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Version : IRCDMessage + struct CoreExport Version + : IRCDMessage { Version(Module *creator, const Anope::string &mname = "VERSION") : IRCDMessage(creator, mname, 0) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } void Run(MessageSource &source, const std::vector<Anope::string> ¶ms, const Anope::map<Anope::string> &tags) override; }; - struct CoreExport Whois : IRCDMessage + struct CoreExport Whois + : IRCDMessage { Whois(Module *creator, const Anope::string &mname = "WHOIS") : IRCDMessage(creator, mname, 1) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } diff --git a/include/modes.h b/include/modes.h index 02aef2ebf..b87d1e5b5 100644 --- a/include/modes.h +++ b/include/modes.h @@ -35,7 +35,8 @@ enum ModeClass /** This class is the basis of all modes in Anope */ -class CoreExport Mode : public Base +class CoreExport Mode + : public Base { public: /* Mode name */ @@ -64,7 +65,8 @@ public: /** This class is a user mode, all user modes use this/inherit from this */ -class CoreExport UserMode : public Mode +class CoreExport UserMode + : public Mode { public: /** constructor @@ -74,7 +76,8 @@ public: UserMode(const Anope::string &name, char mc); }; -class CoreExport UserModeParam : public UserMode +class CoreExport UserModeParam + : public UserMode { public: /** constructor @@ -92,7 +95,8 @@ public: /** This class is a channel mode, all channel modes use this/inherit from this */ -class CoreExport ChannelMode : public Mode +class CoreExport ChannelMode + : public Mode { public: /* channel modes that can possibly unwrap this mode */ @@ -123,7 +127,8 @@ public: /** This is a mode for lists, eg b/e/I. These modes should inherit from this */ -class CoreExport ChannelModeList : public ChannelMode +class CoreExport ChannelModeList + : public ChannelMode { public: /** constructor @@ -161,7 +166,8 @@ public: /** This is a mode with a parameter, eg +k/l. These modes should use/inherit from this */ -class CoreExport ChannelModeParam : public ChannelMode +class CoreExport ChannelModeParam + : public ChannelMode { public: /** constructor @@ -183,7 +189,8 @@ public: /** This is a mode that is a channel status, eg +v/h/o/a/q. */ -class CoreExport ChannelModeStatus : public ChannelMode +class CoreExport ChannelModeStatus + : public ChannelMode { public: /* The symbol, eg @ % + */ @@ -206,7 +213,8 @@ public: * but we still have a representation for it. */ template<typename T> -class CoreExport ChannelModeVirtual : public T +class CoreExport ChannelModeVirtual + : public T { Anope::string base; ChannelMode *basech; @@ -239,7 +247,8 @@ public: Anope::string BuildModePrefixList() const; }; -class CoreExport UserModeOperOnly : public UserMode +class CoreExport UserModeOperOnly + : public UserMode { public: UserModeOperOnly(const Anope::string &mname, char um) : UserMode(mname, um) { } @@ -247,7 +256,8 @@ public: bool CanSet(User *u) const override; }; -class CoreExport UserModeNoone : public UserMode +class CoreExport UserModeNoone + : public UserMode { public: UserModeNoone(const Anope::string &mname, char um) : UserMode(mname, um) { } @@ -257,7 +267,8 @@ public: /** Channel mode +k (key) */ -class CoreExport ChannelModeKey : public ChannelModeParam +class CoreExport ChannelModeKey + : public ChannelModeParam { public: ChannelModeKey(char mc) : ChannelModeParam("KEY", mc) { } @@ -267,7 +278,8 @@ public: /** This class is used for oper only channel modes */ -class CoreExport ChannelModeOperOnly : public ChannelMode +class CoreExport ChannelModeOperOnly + : public ChannelMode { public: ChannelModeOperOnly(const Anope::string &mname, char mc) : ChannelMode(mname, mc) { } @@ -278,7 +290,8 @@ public: /** This class is used for channel modes only servers may set */ -class CoreExport ChannelModeNoone : public ChannelMode +class CoreExport ChannelModeNoone + : public ChannelMode { public: ChannelModeNoone(const Anope::string &mname, char mc) : ChannelMode(mname, mc) { } diff --git a/include/modules.h b/include/modules.h index 94bde45aa..de8d560fe 100644 --- a/include/modules.h +++ b/include/modules.h @@ -196,11 +196,15 @@ public: int GetPatch() const; }; -class CoreExport NotImplementedException : public CoreException { }; +class CoreExport NotImplementedException + : public CoreException +{ +}; /** Every module in Anope is actually a class. */ -class CoreExport Module : public Extensible +class CoreExport Module + : public Extensible { private: bool permanent; diff --git a/include/modules/cs_entrymsg.h b/include/modules/cs_entrymsg.h index 95f571f43..8259adf49 100644 --- a/include/modules/cs_entrymsg.h +++ b/include/modules/cs_entrymsg.h @@ -20,7 +20,8 @@ protected: EntryMsg() = default; }; -struct EntryMessageList : Serialize::Checker<std::vector<EntryMsg *> > +struct EntryMessageList + : Serialize::Checker<std::vector<EntryMsg *> > { protected: EntryMessageList() : Serialize::Checker<std::vector<EntryMsg *> >("EntryMsg") { } diff --git a/include/modules/cs_log.h b/include/modules/cs_log.h index 12bc3fcaf..077ee70ed 100644 --- a/include/modules/cs_log.h +++ b/include/modules/cs_log.h @@ -29,7 +29,8 @@ protected: LogSetting() = default; }; -struct LogSettings : Serialize::Checker<std::vector<LogSetting *> > +struct LogSettings + : Serialize::Checker<std::vector<LogSetting *> > { typedef std::vector<LogSetting *>::iterator iterator; diff --git a/include/modules/dns.h b/include/modules/dns.h index a1e5eb71f..25123a504 100644 --- a/include/modules/dns.h +++ b/include/modules/dns.h @@ -88,7 +88,8 @@ namespace DNS }; }; - struct ResourceRecord : Question + struct ResourceRecord + : Question { unsigned int ttl = 0; Anope::string rdata; @@ -113,7 +114,8 @@ namespace DNS /** DNS manager */ - class Manager : public Service + class Manager + : public Service { public: Manager(Module *creator) : Service(creator, "DNS::Manager", "dns/manager") { } @@ -131,7 +133,9 @@ namespace DNS /** A DNS query. */ - class Request : public Timer, public Question + class Request + : public Timer + , public Question { Manager *manager; public: diff --git a/include/modules/encryption.h b/include/modules/encryption.h index 92385d94a..39eab638b 100644 --- a/include/modules/encryption.h +++ b/include/modules/encryption.h @@ -25,7 +25,8 @@ namespace Encryption virtual Hash GetFinalizedHash() = 0; }; - class Provider : public Service + class Provider + : public Service { public: Provider(Module *creator, const Anope::string &sname) : Service(creator, "Encryption::Provider", sname) { } diff --git a/include/modules/httpd.h b/include/modules/httpd.h index 430336236..c755e9dd2 100644 --- a/include/modules/httpd.h +++ b/include/modules/httpd.h @@ -93,7 +93,8 @@ struct HTTPMessage class HTTPClient; class HTTPProvider; -class HTTPPage : public virtual Base +class HTTPPage + : public virtual Base { Anope::string url; Anope::string content_type; @@ -115,7 +116,10 @@ public: virtual bool OnRequest(HTTPProvider *, const Anope::string &, HTTPClient *, HTTPMessage &, HTTPReply &) = 0; }; -class HTTPClient : public ClientSocket, public BinarySocket, public Base +class HTTPClient + : public ClientSocket + , public BinarySocket + , public Base { protected: void WriteClient(const Anope::string &message) @@ -135,7 +139,9 @@ public: virtual void SendReply(HTTPReply *) = 0; }; -class HTTPProvider : public ListenSocket, public Service +class HTTPProvider + : public ListenSocket + , public Service { Anope::string ip; unsigned short port; diff --git a/include/modules/ldap.h b/include/modules/ldap.h index 166e85fe9..37087198d 100644 --- a/include/modules/ldap.h +++ b/include/modules/ldap.h @@ -31,7 +31,8 @@ struct LDAPModification }; typedef std::vector<LDAPModification> LDAPMods; -struct LDAPAttributes : public std::map<Anope::string, std::vector<Anope::string> > +struct LDAPAttributes + : public std::map<Anope::string, std::vector<Anope::string>> { size_t size(const Anope::string &attr) const { @@ -122,7 +123,8 @@ public: virtual void OnDelete() { } }; -class LDAPProvider : public Service +class LDAPProvider + : public Service { public: LDAPProvider(Module *c, const Anope::string &n) : Service(c, "LDAPProvider", n) { } diff --git a/include/modules/ns_cert.h b/include/modules/ns_cert.h index 09857ffd5..2d24cfeae 100644 --- a/include/modules/ns_cert.h +++ b/include/modules/ns_cert.h @@ -63,7 +63,8 @@ public: virtual void Check() = 0; }; -class CertService : public Service +class CertService + : public Service { public: CertService(Module *c) : Service(c, "CertService", "certs") { } diff --git a/include/modules/os_forbid.h b/include/modules/os_forbid.h index 12eeedbf9..19b34a1e6 100644 --- a/include/modules/os_forbid.h +++ b/include/modules/os_forbid.h @@ -31,7 +31,8 @@ protected: ForbidData() = default; }; -class ForbidService : public Service +class ForbidService + : public Service { public: ForbidService(Module *m) : Service(m, "ForbidService", "forbid") { } diff --git a/include/modules/os_ignore.h b/include/modules/os_ignore.h index 1cd24b670..448fa4354 100644 --- a/include/modules/os_ignore.h +++ b/include/modules/os_ignore.h @@ -23,7 +23,8 @@ protected: IgnoreData() = default; }; -class IgnoreService : public Service +class IgnoreService + : public Service { protected: IgnoreService(Module *c) : Service(c, "IgnoreService", "ignore") { } diff --git a/include/modules/os_news.h b/include/modules/os_news.h index 6a7732269..af7619e56 100644 --- a/include/modules/os_news.h +++ b/include/modules/os_news.h @@ -22,7 +22,8 @@ struct NewsMessages const char *msgs[10]; }; -struct NewsItem : Serializable +struct NewsItem + : Serializable { NewsType type; Anope::string text; @@ -32,7 +33,8 @@ struct NewsItem : Serializable NewsItem() : Serializable("NewsItem") { } }; -class NewsService : public Service +class NewsService + : public Service { public: NewsService(Module *m) : Service(m, "NewsService", "news") { } diff --git a/include/modules/os_session.h b/include/modules/os_session.h index f72e6b8b2..5341b4fe0 100644 --- a/include/modules/os_session.h +++ b/include/modules/os_session.h @@ -17,7 +17,8 @@ struct Session Session(const sockaddrs &ip, int len) : addr(ip, len) { } }; -struct Exception : Serializable +struct Exception + : Serializable { Anope::string mask; /* Hosts to which this exception applies */ unsigned limit; /* Session limit for exception */ @@ -31,7 +32,8 @@ struct Exception : Serializable static Serializable* Unserialize(Serializable *obj, Serialize::Data &data); }; -class SessionService : public Service +class SessionService + : public Service { public: typedef std::unordered_map<cidr, Session *, cidr::hash> SessionMap; diff --git a/include/modules/pseudoclients/chanserv.h b/include/modules/pseudoclients/chanserv.h index baf5cafce..c9e11185c 100644 --- a/include/modules/pseudoclients/chanserv.h +++ b/include/modules/pseudoclients/chanserv.h @@ -8,7 +8,8 @@ #pragma once -class ChanServService : public Service +class ChanServService + : public Service { public: ChanServService(Module *m) : Service(m, "ChanServService", "ChanServ") diff --git a/include/modules/pseudoclients/global.h b/include/modules/pseudoclients/global.h index e0b138e8e..73283605d 100644 --- a/include/modules/pseudoclients/global.h +++ b/include/modules/pseudoclients/global.h @@ -8,7 +8,8 @@ #pragma once -class GlobalService : public Service +class GlobalService + : public Service { public: GlobalService(Module *m) : Service(m, "GlobalService", "Global") diff --git a/include/modules/pseudoclients/memoserv.h b/include/modules/pseudoclients/memoserv.h index 8529c775e..845a19f00 100644 --- a/include/modules/pseudoclients/memoserv.h +++ b/include/modules/pseudoclients/memoserv.h @@ -8,7 +8,8 @@ #pragma once -class MemoServService : public Service +class MemoServService + : public Service { public: enum MemoResult diff --git a/include/modules/pseudoclients/nickserv.h b/include/modules/pseudoclients/nickserv.h index a4f2a89b2..58cf93bd9 100644 --- a/include/modules/pseudoclients/nickserv.h +++ b/include/modules/pseudoclients/nickserv.h @@ -8,7 +8,8 @@ #pragma once -class NickServService : public Service +class NickServService + : public Service { public: NickServService(Module *m) : Service(m, "NickServService", "NickServ") diff --git a/include/modules/redis.h b/include/modules/redis.h index 0007922a2..ec990823e 100644 --- a/include/modules/redis.h +++ b/include/modules/redis.h @@ -55,7 +55,8 @@ namespace Redis virtual void OnError(const Anope::string &error) { Log(owner) << error; } }; - class Provider : public Service + class Provider + : public Service { public: Provider(Module *c, const Anope::string &n) : Service(c, "Redis::Provider", n) { } diff --git a/include/modules/sasl.h b/include/modules/sasl.h index 64994a7f8..2b1c6a30d 100644 --- a/include/modules/sasl.h +++ b/include/modules/sasl.h @@ -22,7 +22,8 @@ namespace SASL class Mechanism; struct Session; - class Service : public ::Service + class Service + : public ::Service { public: Service(Module *o) : ::Service(o, "SASL::Service", "sasl") { } @@ -60,7 +61,8 @@ namespace SASL }; /* PLAIN, EXTERNAL, etc */ - class Mechanism : public ::Service + class Mechanism + : public ::Service { public: Mechanism(Module *o, const Anope::string &sname) : Service(o, "SASL::Mechanism", sname) { } @@ -76,7 +78,8 @@ namespace SASL } }; - class IdentifyRequest : public ::IdentifyRequest + class IdentifyRequest + : public ::IdentifyRequest { Anope::string uid; Anope::string hostname, ip; diff --git a/include/modules/sql.h b/include/modules/sql.h index 0f2abc812..59cc7a24b 100644 --- a/include/modules/sql.h +++ b/include/modules/sql.h @@ -11,7 +11,8 @@ namespace SQL { - class Data : public Serialize::Data + class Data + : public Serialize::Data { public: typedef std::map<Anope::string, std::stringstream *> Map; @@ -199,7 +200,8 @@ namespace SQL /** Class providing the SQL service, modules call this to execute queries */ - class Provider : public Service + class Provider + : public Service { public: Provider(Module *c, const Anope::string &n) : Service(c, "SQL::Provider", n) { } diff --git a/include/modules/ssl.h b/include/modules/ssl.h index c56212f03..32bcdb73a 100644 --- a/include/modules/ssl.h +++ b/include/modules/ssl.h @@ -8,7 +8,8 @@ #pragma once -class SSLService : public Service +class SSLService + : public Service { public: SSLService(Module *o, const Anope::string &n) : Service(o, "SSLService", n) { } diff --git a/include/modules/xmlrpc.h b/include/modules/xmlrpc.h index e57f00004..a12a23c9e 100644 --- a/include/modules/xmlrpc.h +++ b/include/modules/xmlrpc.h @@ -34,7 +34,8 @@ public: virtual bool Run(XMLRPCServiceInterface *iface, HTTPClient *client, XMLRPCRequest &request) = 0; }; -class XMLRPCServiceInterface : public Service +class XMLRPCServiceInterface + : public Service { public: XMLRPCServiceInterface(Module *creator, const Anope::string &sname) : Service(creator, "XMLRPCServiceInterface", sname) { } diff --git a/include/protocol.h b/include/protocol.h index 86c1528b4..e2bee5317 100644 --- a/include/protocol.h +++ b/include/protocol.h @@ -17,7 +17,8 @@ #include "modes.h" /* Encapsulates the IRCd protocol we are speaking. */ -class CoreExport IRCDProto : public Service +class CoreExport IRCDProto + : public Service { Anope::string proto_name; @@ -268,7 +269,8 @@ enum IRCDMessageFlag IRCDMESSAGE_REQUIRE_USER }; -class CoreExport IRCDMessage : public Service +class CoreExport IRCDMessage + : public Service { Anope::string name; unsigned param_count; diff --git a/include/regchannel.h b/include/regchannel.h index a3315a5e1..29c203cf3 100644 --- a/include/regchannel.h +++ b/include/regchannel.h @@ -21,7 +21,8 @@ typedef Anope::hash_map<ChannelInfo *> registered_channel_map; extern CoreExport Serialize::Checker<registered_channel_map> RegisteredChannelList; /* AutoKick data. */ -class CoreExport AutoKick : public Serializable +class CoreExport AutoKick + : public Serializable { public: /* Channel this autokick is on */ @@ -43,7 +44,9 @@ public: /* It matters that Base is here before Extensible (it is inherited by Serializable) */ -class CoreExport ChannelInfo : public Serializable, public Extensible +class CoreExport ChannelInfo + : public Serializable + , public Extensible { /* channels who reference this one */ Anope::map<int> references; diff --git a/include/regexpr.h b/include/regexpr.h index fdb0cce50..536c891c1 100644 --- a/include/regexpr.h +++ b/include/regexpr.h @@ -15,7 +15,8 @@ #include "anope.h" #include "service.h" -class CoreExport RegexException : public CoreException +class CoreExport RegexException + : public CoreException { public: RegexException(const Anope::string &reason = "") : CoreException(reason) { } @@ -34,7 +35,8 @@ public: virtual bool Matches(const Anope::string &str) = 0; }; -class CoreExport RegexProvider : public Service +class CoreExport RegexProvider + : public Service { public: RegexProvider(Module *o, const Anope::string &n) : Service(o, "Regex", n) { } diff --git a/include/serialize.h b/include/serialize.h index bd6a311a0..b0739e683 100644 --- a/include/serialize.h +++ b/include/serialize.h @@ -49,7 +49,8 @@ namespace Serialize * abstract data types (Serialize::Data), and then reconstructed or * updated later at any time. */ -class CoreExport Serializable : public virtual Base +class CoreExport Serializable + : public virtual Base { private: /* A list of every serializable item in Anope. @@ -107,7 +108,8 @@ public: * of class that inherits from Serializable. Used for unserializing objects * of this type, as it requires a function pointer to a static member function. */ -class CoreExport Serialize::Type : public Base +class CoreExport Serialize::Type + : public Base { typedef Serializable* (*unserialize_func)(Serializable *obj, Serialize::Data &); @@ -240,7 +242,8 @@ public: * destructed. */ template<typename T> -class Serialize::Reference : public ReferenceBase +class Serialize::Reference + : public ReferenceBase { protected: T *ref = nullptr; diff --git a/include/servers.h b/include/servers.h index e83a5ac55..a2a0bfdfb 100644 --- a/include/servers.h +++ b/include/servers.h @@ -37,7 +37,8 @@ namespace Servers /** Class representing a server */ -class CoreExport Server : public Extensible +class CoreExport Server + : public Extensible { private: /* Server name */ diff --git a/include/service.h b/include/service.h index c84cb7bb9..5a59fa303 100644 --- a/include/service.h +++ b/include/service.h @@ -20,7 +20,8 @@ * such as commands, use this. This is also used for modules * that publish a service (m_ssl_openssl, etc). */ -class CoreExport Service : public virtual Base +class CoreExport Service + : public virtual Base { static std::map<Anope::string, std::map<Anope::string, Service *> > Services; static std::map<Anope::string, std::map<Anope::string, Anope::string> > Aliases; @@ -115,7 +116,8 @@ public: /** Like Reference, but used to refer to a Service. */ template<typename T> -class ServiceReference : public Reference<T> +class ServiceReference + : public Reference<T> { Anope::string type; Anope::string name; diff --git a/include/sockets.h b/include/sockets.h index fc10fec4e..e7311e727 100644 --- a/include/sockets.h +++ b/include/sockets.h @@ -126,7 +126,8 @@ public: }; }; -class CoreExport SocketException : public CoreException +class CoreExport SocketException + : public CoreException { public: /** Constructor for socket exceptions @@ -286,7 +287,8 @@ public: virtual void ProcessError(); }; -class CoreExport BufferedSocket : public virtual Socket +class CoreExport BufferedSocket + : public virtual Socket { protected: /* Things read from the socket */ @@ -333,7 +335,8 @@ public: int WriteBufferLen() const; }; -class CoreExport BinarySocket : public virtual Socket +class CoreExport BinarySocket + : public virtual Socket { protected: struct DataBlock @@ -378,7 +381,8 @@ public: virtual bool Read(const char *buffer, size_t l); }; -class CoreExport ListenSocket : public virtual Socket +class CoreExport ListenSocket + : public virtual Socket { public: /** Constructor @@ -402,7 +406,8 @@ public: virtual ClientSocket *OnAccept(int fd, const sockaddrs &addr) = 0; }; -class CoreExport ConnectionSocket : public virtual Socket +class CoreExport ConnectionSocket + : public virtual Socket { public: /* Sockaddrs for connection ip/port */ @@ -435,7 +440,8 @@ public: virtual void OnError(const Anope::string &error); }; -class CoreExport ClientSocket : public virtual Socket +class CoreExport ClientSocket + : public virtual Socket { public: /* Listen socket this connection came from */ @@ -469,7 +475,8 @@ public: virtual void OnError(const Anope::string &error); }; -class CoreExport Pipe : public Socket +class CoreExport Pipe + : public Socket { public: /** The FD of the write pipe diff --git a/include/threadengine.h b/include/threadengine.h index 7b7b88c9f..79e545166 100644 --- a/include/threadengine.h +++ b/include/threadengine.h @@ -14,7 +14,9 @@ #include "sockets.h" #include "extensible.h" -class CoreExport Thread : public Pipe, public Extensible +class CoreExport Thread + : public Pipe + , public Extensible { private: /* Set to true to tell the thread to finish and we are waiting for it */ @@ -88,7 +90,8 @@ public: bool TryLock(); }; -class CoreExport Condition : public Mutex +class CoreExport Condition + : public Mutex { private: /* A condition */ diff --git a/include/uplink.h b/include/uplink.h index a6982b41b..6646f58cb 100644 --- a/include/uplink.h +++ b/include/uplink.h @@ -20,7 +20,9 @@ namespace Uplink } /* This is the socket to our uplink */ -class UplinkSocket : public ConnectionSocket, public BufferedSocket +class UplinkSocket + : public ConnectionSocket + , public BufferedSocket { public: bool error; diff --git a/include/users.h b/include/users.h index 02fb48b60..2c9779ea3 100644 --- a/include/users.h +++ b/include/users.h @@ -28,7 +28,10 @@ extern CoreExport unsigned MaxUserCount; extern CoreExport time_t MaxUserTime; /* Online user and channel data. */ -class CoreExport User : public virtual Base, public Extensible, public CommandReply +class CoreExport User + : public virtual Base + , public Extensible + , public CommandReply { /* true if the user was quit or killed */ bool quit; diff --git a/include/xline.h b/include/xline.h index 526831d06..19dd0a5c0 100644 --- a/include/xline.h +++ b/include/xline.h @@ -13,7 +13,8 @@ #include "sockets.h" /* An Xline, eg, anything added with operserv/akill, or any of the operserv/sxline commands */ -class CoreExport XLine : public Serializable +class CoreExport XLine + : public Serializable { void Init(); Anope::string nick, user, host, real; @@ -48,7 +49,8 @@ public: }; /* Managers XLines. There is one XLineManager per type of XLine. */ -class CoreExport XLineManager : public Service +class CoreExport XLineManager + : public Service { char type; /* List of XLines in this XLineManager */ diff --git a/modules/bs_autoassign.cpp b/modules/bs_autoassign.cpp index 9fc5ca7ce..91a65d70a 100644 --- a/modules/bs_autoassign.cpp +++ b/modules/bs_autoassign.cpp @@ -9,7 +9,8 @@ #include "module.h" -class BSAutoAssign : public Module +class BSAutoAssign + : public Module { public: BSAutoAssign(const Anope::string &modname, const Anope::string &creator) : Module(modname, creator, VENDOR) diff --git a/modules/commands/bs_assign.cpp b/modules/commands/bs_assign.cpp index ccce7571a..e1e744842 100644 --- a/modules/commands/bs_assign.cpp +++ b/modules/commands/bs_assign.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandBSAssign : public Command +class CommandBSAssign + : public Command { public: CommandBSAssign(Module *creator) : Command(creator, "botserv/assign", 2, 2) @@ -82,7 +83,8 @@ public: } }; -class CommandBSUnassign : public Command +class CommandBSUnassign + : public Command { public: CommandBSUnassign(Module *creator) : Command(creator, "botserv/unassign", 1, 1) @@ -145,7 +147,8 @@ public: } }; -class CommandBSSetNoBot : public Command +class CommandBSSetNoBot + : public Command { public: CommandBSSetNoBot(Module *creator, const Anope::string &sname = "botserv/set/nobot") : Command(creator, sname, 2, 2) @@ -202,7 +205,8 @@ public: } }; -class BSAssign : public Module +class BSAssign + : public Module { ExtensibleItem<bool> nobot; diff --git a/modules/commands/bs_badwords.cpp b/modules/commands/bs_badwords.cpp index 82e4e20b3..cf863e442 100644 --- a/modules/commands/bs_badwords.cpp +++ b/modules/commands/bs_badwords.cpp @@ -12,7 +12,9 @@ #include "module.h" #include "modules/bs_badwords.h" -struct BadWordImpl : BadWord, Serializable +struct BadWordImpl + : BadWord + , Serializable { BadWordImpl() : Serializable("BadWord") { } ~BadWordImpl() override; @@ -27,7 +29,8 @@ struct BadWordImpl : BadWord, Serializable static Serializable* Unserialize(Serializable *obj, Serialize::Data &); }; -struct BadWordsImpl : BadWords +struct BadWordsImpl + : BadWords { Serialize::Reference<ChannelInfo> ci; typedef std::vector<BadWordImpl *> list; @@ -144,7 +147,8 @@ Serializable* BadWordImpl::Unserialize(Serializable *obj, Serialize::Data &data) return bw; } -class BadwordsDelCallback : public NumberList +class BadwordsDelCallback + : public NumberList { CommandSource &source; ChannelInfo *ci; @@ -181,7 +185,8 @@ public: } }; -class CommandBSBadwords : public Command +class CommandBSBadwords + : public Command { private: void DoList(CommandSource &source, ChannelInfo *ci, const Anope::string &word) @@ -200,7 +205,8 @@ private: } else if (!word.empty() && word.find_first_not_of("1234567890,-") == Anope::string::npos) { - class BadwordsListCallback : public NumberList + class BadwordsListCallback + : public NumberList { ListFormatter &list; BadWords *bw; @@ -453,7 +459,8 @@ public: } }; -class BSBadwords : public Module +class BSBadwords + : public Module { CommandBSBadwords commandbsbadwords; ExtensibleItem<BadWordsImpl> badwords; diff --git a/modules/commands/bs_bot.cpp b/modules/commands/bs_bot.cpp index 6499e3baa..e882d3e04 100644 --- a/modules/commands/bs_bot.cpp +++ b/modules/commands/bs_bot.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandBSBot : public Command +class CommandBSBot + : public Command { private: void DoAdd(CommandSource &source, const std::vector<Anope::string> ¶ms) @@ -370,7 +371,8 @@ public: } }; -class BSBot : public Module +class BSBot + : public Module { CommandBSBot commandbsbot; diff --git a/modules/commands/bs_botlist.cpp b/modules/commands/bs_botlist.cpp index a62cfe174..828b5af99 100644 --- a/modules/commands/bs_botlist.cpp +++ b/modules/commands/bs_botlist.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandBSBotList : public Command +class CommandBSBotList + : public Command { public: CommandBSBotList(Module *creator) : Command(creator, "botserv/botlist", 0, 0) @@ -65,7 +66,8 @@ public: } }; -class BSBotList : public Module +class BSBotList + : public Module { CommandBSBotList commandbsbotlist; diff --git a/modules/commands/bs_control.cpp b/modules/commands/bs_control.cpp index 1c7f0ddb4..1230f03e1 100644 --- a/modules/commands/bs_control.cpp +++ b/modules/commands/bs_control.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandBSSay : public Command +class CommandBSSay + : public Command { public: CommandBSSay(Module *creator) : Command(creator, "botserv/say", 2, 2) @@ -71,7 +72,8 @@ public: } }; -class CommandBSAct : public Command +class CommandBSAct + : public Command { public: CommandBSAct(Module *creator) : Command(creator, "botserv/act", 2, 2) @@ -130,7 +132,8 @@ public: } }; -class BSControl : public Module +class BSControl + : public Module { CommandBSSay commandbssay; CommandBSAct commandbsact; diff --git a/modules/commands/bs_info.cpp b/modules/commands/bs_info.cpp index 4c2b1d4e9..f8381836d 100644 --- a/modules/commands/bs_info.cpp +++ b/modules/commands/bs_info.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandBSInfo : public Command +class CommandBSInfo + : public Command { private: void send_bot_channels(std::vector<Anope::string> &buffers, const BotInfo *bi) @@ -117,7 +118,8 @@ public: } }; -class BSInfo : public Module +class BSInfo + : public Module { CommandBSInfo commandbsinfo; diff --git a/modules/commands/bs_kick.cpp b/modules/commands/bs_kick.cpp index e1919e241..e02c6cab8 100644 --- a/modules/commands/bs_kick.cpp +++ b/modules/commands/bs_kick.cpp @@ -15,7 +15,8 @@ static Module *me; -struct KickerDataImpl : KickerData +struct KickerDataImpl + : KickerData { KickerDataImpl(Extensible *obj) { @@ -37,7 +38,8 @@ struct KickerDataImpl : KickerData ci->Shrink<KickerData>("kickerdata"); } - struct ExtensibleItem : ::ExtensibleItem<KickerDataImpl> + struct ExtensibleItem + : ::ExtensibleItem<KickerDataImpl> { ExtensibleItem(Module *m, const Anope::string &ename) : ::ExtensibleItem<KickerDataImpl>(m, ename) { } @@ -115,7 +117,8 @@ struct KickerDataImpl : KickerData }; }; -class CommandBSKick : public Command +class CommandBSKick + : public Command { public: CommandBSKick(Module *creator) : Command(creator, "botserv/kick", 0) @@ -159,7 +162,8 @@ public: } }; -class CommandBSKickBase : public Command +class CommandBSKickBase + : public Command { public: CommandBSKickBase(Module *creator, const Anope::string &cname, int minarg, int maxarg) : Command(creator, cname, minarg, maxarg) @@ -244,7 +248,8 @@ protected: } }; -class CommandBSKickAMSG : public CommandBSKickBase +class CommandBSKickAMSG + : public CommandBSKickBase { public: CommandBSKickAMSG(Module *creator) : CommandBSKickBase(creator, "botserv/kick/amsg", 2, 3) @@ -280,7 +285,8 @@ public: } }; -class CommandBSKickBadwords : public CommandBSKickBase +class CommandBSKickBadwords + : public CommandBSKickBase { public: CommandBSKickBadwords(Module *creator) : CommandBSKickBase(creator, "botserv/kick/badwords", 2, 3) @@ -319,7 +325,8 @@ public: } }; -class CommandBSKickBolds : public CommandBSKickBase +class CommandBSKickBolds + : public CommandBSKickBase { public: CommandBSKickBolds(Module *creator) : CommandBSKickBase(creator, "botserv/kick/bolds", 2, 3) @@ -353,7 +360,8 @@ public: } }; -class CommandBSKickCaps : public CommandBSKickBase +class CommandBSKickCaps + : public CommandBSKickBase { public: CommandBSKickCaps(Module *creator) : CommandBSKickBase(creator, "botserv/kick/caps", 2, 5) @@ -449,7 +457,8 @@ public: } }; -class CommandBSKickColors : public CommandBSKickBase +class CommandBSKickColors + : public CommandBSKickBase { public: CommandBSKickColors(Module *creator) : CommandBSKickBase(creator, "botserv/kick/colors", 2, 3) @@ -483,7 +492,8 @@ public: } }; -class CommandBSKickFlood : public CommandBSKickBase +class CommandBSKickFlood + : public CommandBSKickBase { public: CommandBSKickFlood(Module *creator) : CommandBSKickBase(creator, "botserv/kick/flood", 2, 5) @@ -581,7 +591,8 @@ public: } }; -class CommandBSKickItalics : public CommandBSKickBase +class CommandBSKickItalics + : public CommandBSKickBase { public: CommandBSKickItalics(Module *creator) : CommandBSKickBase(creator, "botserv/kick/italics", 2, 3) @@ -615,7 +626,8 @@ public: } }; -class CommandBSKickRepeat : public CommandBSKickBase +class CommandBSKickRepeat + : public CommandBSKickBase { public: CommandBSKickRepeat(Module *creator) : CommandBSKickBase(creator, "botserv/kick/repeat", 2, 4) @@ -716,7 +728,8 @@ public: } }; -class CommandBSKickReverses : public CommandBSKickBase +class CommandBSKickReverses + : public CommandBSKickBase { public: CommandBSKickReverses(Module *creator) : CommandBSKickBase(creator, "botserv/kick/reverses", 2, 3) @@ -750,7 +763,8 @@ public: } }; -class CommandBSKickUnderlines : public CommandBSKickBase +class CommandBSKickUnderlines + : public CommandBSKickBase { public: CommandBSKickUnderlines(Module *creator) : CommandBSKickBase(creator, "botserv/kick/underlines", 2, 3) @@ -784,7 +798,8 @@ public: } }; -class CommandBSSetDontKickOps : public Command +class CommandBSSetDontKickOps + : public Command { public: CommandBSSetDontKickOps(Module *creator, const Anope::string &sname = "botserv/set/dontkickops") : Command(creator, sname, 2, 2) @@ -849,7 +864,8 @@ public: } }; -class CommandBSSetDontKickVoices : public Command +class CommandBSSetDontKickVoices + : public Command { public: CommandBSSetDontKickVoices(Module *creator, const Anope::string &sname = "botserv/set/dontkickvoices") : Command(creator, sname, 2, 2) @@ -985,7 +1001,8 @@ struct UserData Anope::string lastline; }; -class BanDataPurger : public Timer +class BanDataPurger + : public Timer { public: BanDataPurger(Module *o) : Timer(o, 300, Anope::CurTime, true) { } @@ -1007,7 +1024,8 @@ public: } }; -class BSKick : public Module +class BSKick + : public Module { ExtensibleItem<BanData> bandata; ExtensibleItem<UserData> userdata; diff --git a/modules/commands/bs_set.cpp b/modules/commands/bs_set.cpp index 17d3eac1e..b2ffa24cb 100644 --- a/modules/commands/bs_set.cpp +++ b/modules/commands/bs_set.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandBSSet : public Command +class CommandBSSet + : public Command { public: CommandBSSet(Module *creator) : Command(creator, "botserv/set", 3, 3) @@ -64,10 +65,12 @@ public: } }; -class CommandBSSetBanExpire : public Command +class CommandBSSetBanExpire + : public Command { public: - class UnbanTimer : public Timer + class UnbanTimer + : public Timer { Anope::string chname; Anope::string mask; @@ -151,7 +154,8 @@ public: } }; -class CommandBSSetPrivate : public Command +class CommandBSSetPrivate + : public Command { public: CommandBSSetPrivate(Module *creator, const Anope::string &sname = "botserv/set/private") : Command(creator, sname, 2, 2) @@ -201,7 +205,8 @@ public: } }; -class BSSet : public Module +class BSSet + : public Module { CommandBSSet commandbsset; CommandBSSetBanExpire commandbssetbanexpire; diff --git a/modules/commands/cs_access.cpp b/modules/commands/cs_access.cpp index 566d98889..939cc9ad4 100644 --- a/modules/commands/cs_access.cpp +++ b/modules/commands/cs_access.cpp @@ -20,7 +20,8 @@ static inline void reset_levels(ChannelInfo *ci) ci->SetLevel(priv, level); } -class AccessChanAccess : public ChanAccess +class AccessChanAccess + : public ChanAccess { public: int level = 0; @@ -67,7 +68,8 @@ public: } }; -class AccessAccessProvider : public AccessProvider +class AccessAccessProvider + : public AccessProvider { public: static AccessAccessProvider *me; @@ -84,7 +86,8 @@ public: }; AccessAccessProvider* AccessAccessProvider::me; -class CommandCSAccess : public Command +class CommandCSAccess + : public Command { void DoAdd(CommandSource &source, ChannelInfo *ci, const std::vector<Anope::string> ¶ms) { @@ -257,7 +260,8 @@ class CommandCSAccess : public Command source.Reply(_("%s access list is empty."), ci->name.c_str()); else if (isdigit(mask[0]) && mask.find_first_not_of("1234567890,-") == Anope::string::npos) { - class AccessDelCallback : public NumberList + class AccessDelCallback + : public NumberList { CommandSource &source; ChannelInfo *ci; @@ -361,7 +365,8 @@ class CommandCSAccess : public Command source.Reply(_("%s access list is empty."), ci->name.c_str()); else if (!nick.empty() && nick.find_first_not_of("1234567890,-") == Anope::string::npos) { - class AccessListCallback : public NumberList + class AccessListCallback + : public NumberList { ListFormatter &list; ChannelInfo *ci; @@ -633,7 +638,8 @@ public: } }; -class CommandCSLevels : public Command +class CommandCSLevels + : public Command { void DoSet(CommandSource &source, ChannelInfo *ci, const std::vector<Anope::string> ¶ms) { @@ -857,7 +863,8 @@ public: } }; -class CSAccess : public Module +class CSAccess + : public Module { AccessAccessProvider accessprovider; CommandCSAccess commandcsaccess; diff --git a/modules/commands/cs_akick.cpp b/modules/commands/cs_akick.cpp index 78666e79b..99c1dd2ee 100644 --- a/modules/commands/cs_akick.cpp +++ b/modules/commands/cs_akick.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandCSAKick : public Command +class CommandCSAKick + : public Command { void Enforce(CommandSource &source, ChannelInfo *ci) { @@ -203,7 +204,8 @@ class CommandCSAKick : public Command /* Special case: is it a number/list? Only do search if it isn't. */ if (isdigit(mask[0]) && mask.find_first_not_of("1234567890,-") == Anope::string::npos) { - class AkickDelCallback : public NumberList + class AkickDelCallback + : public NumberList { CommandSource &source; ChannelInfo *ci; @@ -280,7 +282,8 @@ class CommandCSAKick : public Command if (!mask.empty() && isdigit(mask[0]) && mask.find_first_not_of("1234567890,-") == Anope::string::npos) { - class AkickListCallback : public NumberList + class AkickListCallback + : public NumberList { ListFormatter &list; ChannelInfo *ci; @@ -525,7 +528,8 @@ public: } }; -class CSAKick : public Module +class CSAKick + : public Module { CommandCSAKick commandcsakick; diff --git a/modules/commands/cs_ban.cpp b/modules/commands/cs_ban.cpp index 4bf0315bc..5419ac263 100644 --- a/modules/commands/cs_ban.cpp +++ b/modules/commands/cs_ban.cpp @@ -13,7 +13,8 @@ static Module *me; -class TempBan : public Timer +class TempBan + : public Timer { private: Anope::string channel; @@ -31,7 +32,8 @@ public: } }; -class CommandCSBan : public Command +class CommandCSBan + : public Command { public: CommandCSBan(Module *creator) : Command(creator, "chanserv/ban", 2, 4) @@ -237,7 +239,8 @@ public: } }; -class CSBan : public Module +class CSBan + : public Module { CommandCSBan commandcsban; diff --git a/modules/commands/cs_clone.cpp b/modules/commands/cs_clone.cpp index f82bdbe08..5201b332c 100644 --- a/modules/commands/cs_clone.cpp +++ b/modules/commands/cs_clone.cpp @@ -12,7 +12,8 @@ #include "module.h" #include "modules/bs_badwords.h" -class CommandCSClone : public Command +class CommandCSClone + : public Command { void CopySetting(ChannelInfo *ci, ChannelInfo *target_ci, const Anope::string &setting) { @@ -246,7 +247,8 @@ public: } }; -class CSClone : public Module +class CSClone + : public Module { CommandCSClone commandcsclone; diff --git a/modules/commands/cs_drop.cpp b/modules/commands/cs_drop.cpp index 5fa94137e..4f0b3f776 100644 --- a/modules/commands/cs_drop.cpp +++ b/modules/commands/cs_drop.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandCSDrop : public Command +class CommandCSDrop + : public Command { public: CommandCSDrop(Module *creator) : Command(creator, "chanserv/drop", 1, 2) @@ -81,7 +82,8 @@ public: } }; -class CSDrop : public Module +class CSDrop + : public Module { CommandCSDrop commandcsdrop; diff --git a/modules/commands/cs_enforce.cpp b/modules/commands/cs_enforce.cpp index 248275a01..dc60e9c5c 100644 --- a/modules/commands/cs_enforce.cpp +++ b/modules/commands/cs_enforce.cpp @@ -13,7 +13,8 @@ #include "module.h" -class CommandCSEnforce : public Command +class CommandCSEnforce + : public Command { private: void DoSecureOps(CommandSource &source, ChannelInfo *ci) @@ -262,7 +263,8 @@ public: } }; -class CSEnforce : public Module +class CSEnforce + : public Module { CommandCSEnforce commandcsenforce; diff --git a/modules/commands/cs_entrymsg.cpp b/modules/commands/cs_entrymsg.cpp index 2659428a4..43055d5e5 100644 --- a/modules/commands/cs_entrymsg.cpp +++ b/modules/commands/cs_entrymsg.cpp @@ -12,7 +12,9 @@ #include "module.h" #include "modules/cs_entrymsg.h" -struct EntryMsgImpl : EntryMsg, Serializable +struct EntryMsgImpl + : EntryMsg + , Serializable { EntryMsgImpl() : Serializable("EntryMsg") { @@ -39,7 +41,8 @@ struct EntryMsgImpl : EntryMsg, Serializable static Serializable* Unserialize(Serializable *obj, Serialize::Data &data); }; -struct EntryMessageListImpl : EntryMessageList +struct EntryMessageListImpl + : EntryMessageList { EntryMessageListImpl(Extensible *) { } @@ -97,7 +100,8 @@ Serializable* EntryMsgImpl::Unserialize(Serializable *obj, Serialize::Data &data return m; } -class CommandEntryMessage : public Command +class CommandEntryMessage + : public Command { private: void DoList(CommandSource &source, ChannelInfo *ci) @@ -260,7 +264,8 @@ public: } }; -class CSEntryMessage : public Module +class CSEntryMessage + : public Module { CommandEntryMessage commandentrymsg; ExtensibleItem<EntryMessageListImpl> eml; diff --git a/modules/commands/cs_flags.cpp b/modules/commands/cs_flags.cpp index d35f96d45..795dfa167 100644 --- a/modules/commands/cs_flags.cpp +++ b/modules/commands/cs_flags.cpp @@ -13,7 +13,8 @@ static std::map<Anope::string, char> defaultFlags; -class FlagsChanAccess : public ChanAccess +class FlagsChanAccess + : public ChanAccess { public: std::set<char> flags; @@ -59,7 +60,8 @@ public: } }; -class FlagsAccessProvider : public AccessProvider +class FlagsAccessProvider + : public AccessProvider { public: static FlagsAccessProvider *ap; @@ -76,7 +78,8 @@ public: }; FlagsAccessProvider* FlagsAccessProvider::ap; -class CommandCSFlags : public Command +class CommandCSFlags + : public Command { void DoModify(CommandSource &source, ChannelInfo *ci, Anope::string mask, const Anope::string &flags, const Anope::string &description) { @@ -475,7 +478,8 @@ public: } }; -class CSFlags : public Module +class CSFlags + : public Module { FlagsAccessProvider accessprovider; CommandCSFlags commandcsflags; diff --git a/modules/commands/cs_getkey.cpp b/modules/commands/cs_getkey.cpp index 3c573d3ec..4cec2f87b 100644 --- a/modules/commands/cs_getkey.cpp +++ b/modules/commands/cs_getkey.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandCSGetKey : public Command +class CommandCSGetKey + : public Command { public: CommandCSGetKey(Module *creator) : Command(creator, "chanserv/getkey", 1, 1) @@ -59,7 +60,8 @@ public: } }; -class CSGetKey : public Module +class CSGetKey + : public Module { CommandCSGetKey commandcsgetkey; diff --git a/modules/commands/cs_info.cpp b/modules/commands/cs_info.cpp index 03ee6ec0f..0c5c91091 100644 --- a/modules/commands/cs_info.cpp +++ b/modules/commands/cs_info.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandCSInfo : public Command +class CommandCSInfo + : public Command { public: CommandCSInfo(Module *creator) : Command(creator, "chanserv/info", 1, 2) @@ -83,7 +84,8 @@ public: } }; -class CSInfo : public Module +class CSInfo + : public Module { CommandCSInfo commandcsinfo; diff --git a/modules/commands/cs_invite.cpp b/modules/commands/cs_invite.cpp index 8d4f13192..79e588f1e 100644 --- a/modules/commands/cs_invite.cpp +++ b/modules/commands/cs_invite.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandCSInvite : public Command +class CommandCSInvite + : public Command { public: CommandCSInvite(Module *creator) : Command(creator, "chanserv/invite", 1, 3) @@ -97,7 +98,8 @@ public: } }; -class CSInvite : public Module +class CSInvite + : public Module { CommandCSInvite commandcsinvite; diff --git a/modules/commands/cs_kick.cpp b/modules/commands/cs_kick.cpp index 11b7d624b..2756f3a59 100644 --- a/modules/commands/cs_kick.cpp +++ b/modules/commands/cs_kick.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandCSKick : public Command +class CommandCSKick + : public Command { public: CommandCSKick(Module *creator) : Command(creator, "chanserv/kick", 2, 3) @@ -133,7 +134,8 @@ public: } }; -class CSKick : public Module +class CSKick + : public Module { CommandCSKick commandcskick; diff --git a/modules/commands/cs_list.cpp b/modules/commands/cs_list.cpp index d367f903c..6c07db258 100644 --- a/modules/commands/cs_list.cpp +++ b/modules/commands/cs_list.cpp @@ -12,7 +12,8 @@ #include "module.h" #include "modules/cs_mode.h" -class CommandCSList : public Command +class CommandCSList + : public Command { public: CommandCSList(Module *creator) : Command(creator, "chanserv/list", 1, 2) @@ -170,7 +171,8 @@ public: } }; -class CommandCSSetPrivate : public Command +class CommandCSSetPrivate + : public Command { public: CommandCSSetPrivate(Module *creator, const Anope::string &cname = "chanserv/set/private") : Command(creator, cname, 2, 2) @@ -238,7 +240,8 @@ public: } }; -class CSList : public Module +class CSList + : public Module { CommandCSList commandcslist; CommandCSSetPrivate commandcssetprivate; diff --git a/modules/commands/cs_log.cpp b/modules/commands/cs_log.cpp index b955255f4..ebc64f8c7 100644 --- a/modules/commands/cs_log.cpp +++ b/modules/commands/cs_log.cpp @@ -12,7 +12,9 @@ #include "module.h" #include "modules/cs_log.h" -struct LogSettingImpl : LogSetting, Serializable +struct LogSettingImpl + : LogSetting + , Serializable { LogSettingImpl() : Serializable("LogSetting") { @@ -77,7 +79,8 @@ struct LogSettingImpl : LogSetting, Serializable } }; -struct LogSettingsImpl : LogSettings +struct LogSettingsImpl + : LogSettings { LogSettingsImpl(Extensible *) { } @@ -97,7 +100,8 @@ struct LogSettingsImpl : LogSettings } }; -class CommandCSLog : public Command +class CommandCSLog + : public Command { public: CommandCSLog(Module *creator) : Command(creator, "chanserv/log", 1, 4) @@ -281,7 +285,8 @@ public: } }; -class CSLog : public Module +class CSLog + : public Module { ServiceReference<MemoServService> MSService; CommandCSLog commandcslog; diff --git a/modules/commands/cs_mode.cpp b/modules/commands/cs_mode.cpp index 27cd08fcb..1cdec547a 100644 --- a/modules/commands/cs_mode.cpp +++ b/modules/commands/cs_mode.cpp @@ -12,7 +12,9 @@ #include "module.h" #include "modules/cs_mode.h" -struct ModeLockImpl : ModeLock, Serializable +struct ModeLockImpl + : ModeLock + , Serializable { ModeLockImpl() : Serializable("ModeLock") { @@ -33,7 +35,8 @@ struct ModeLockImpl : ModeLock, Serializable static Serializable* Unserialize(Serializable *obj, Serialize::Data &data); }; -struct ModeLocksImpl : ModeLocks +struct ModeLocksImpl + : ModeLocks { Serialize::Reference<ChannelInfo> ci; Serialize::Checker<ModeList> mlocks; @@ -241,7 +244,8 @@ Serializable* ModeLockImpl::Unserialize(Serializable *obj, Serialize::Data &data return ml; } -class CommandCSMode : public Command +class CommandCSMode + : public Command { bool CanSet(CommandSource &source, ChannelInfo *ci, ChannelMode *cm, bool self) { @@ -789,7 +793,8 @@ public: static Anope::map<std::pair<bool, Anope::string> > modes; -class CommandCSModes : public Command +class CommandCSModes + : public Command { public: CommandCSModes(Module *creator) : Command(creator, "chanserv/modes", 1, 2) @@ -906,7 +911,8 @@ public: } }; -class CSMode : public Module +class CSMode + : public Module { CommandCSMode commandcsmode; CommandCSModes commandcsmodes; diff --git a/modules/commands/cs_register.cpp b/modules/commands/cs_register.cpp index 14d23f1f5..e16413b79 100644 --- a/modules/commands/cs_register.cpp +++ b/modules/commands/cs_register.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandCSRegister : public Command +class CommandCSRegister + : public Command { public: CommandCSRegister(Module *creator) : Command(creator, "chanserv/register", 1, 2) @@ -110,7 +111,8 @@ public: }; -class CSRegister : public Module +class CSRegister + : public Module { CommandCSRegister commandcsregister; diff --git a/modules/commands/cs_seen.cpp b/modules/commands/cs_seen.cpp index bf7f9f853..378d78105 100644 --- a/modules/commands/cs_seen.cpp +++ b/modules/commands/cs_seen.cpp @@ -22,7 +22,8 @@ static SeenInfo *FindInfo(const Anope::string &nick); typedef Anope::hash_map<SeenInfo *> database_map; database_map database; -struct SeenInfo : Serializable +struct SeenInfo + : Serializable { Anope::string nick; Anope::string vhost; @@ -109,7 +110,8 @@ static bool ShouldHide(const Anope::string &channel, User *u) return false; } -class CommandOSSeen : public Command +class CommandOSSeen + : public Command { public: CommandOSSeen(Module *creator) : Command(creator, "operserv/seen", 1, 2) @@ -180,7 +182,8 @@ public: } }; -class CommandSeen : public Command +class CommandSeen + : public Command { void SimpleSeen(CommandSource &source, const std::vector<Anope::string> ¶ms) { @@ -368,7 +371,8 @@ public: } }; -class CSSeen : public Module +class CSSeen + : public Module { Serialize::Type seeninfo_type; CommandSeen commandseen; diff --git a/modules/commands/cs_set.cpp b/modules/commands/cs_set.cpp index 973a01b23..ba44f14e2 100644 --- a/modules/commands/cs_set.cpp +++ b/modules/commands/cs_set.cpp @@ -12,7 +12,8 @@ #include "module.h" #include "modules/cs_mode.h" -class CommandCSSet : public Command +class CommandCSSet + : public Command { public: CommandCSSet(Module *creator) : Command(creator, "chanserv/set", 2, 3) @@ -64,7 +65,8 @@ public: } }; -class CommandCSSetAutoOp : public Command +class CommandCSSetAutoOp + : public Command { public: CommandCSSetAutoOp(Module *creator, const Anope::string &cname = "chanserv/set/autoop") : Command(creator, cname, 2, 2) @@ -127,7 +129,8 @@ public: } }; -class CommandCSSetBanType : public Command +class CommandCSSetBanType + : public Command { public: CommandCSSetBanType(Module *creator, const Anope::string &cname = "chanserv/set/bantype") : Command(creator, cname, 2, 2) @@ -194,7 +197,8 @@ public: } }; -class CommandCSSetDescription : public Command +class CommandCSSetDescription + : public Command { public: CommandCSSetDescription(Module *creator, const Anope::string &cname = "chanserv/set/description") : Command(creator, cname, 1, 2) @@ -256,7 +260,8 @@ public: } }; -class CommandCSSetFounder : public Command +class CommandCSSetFounder + : public Command { public: CommandCSSetFounder(Module *creator, const Anope::string &cname = "chanserv/set/founder") : Command(creator, cname, 2, 2) @@ -325,7 +330,8 @@ public: } }; -class CommandCSSetKeepModes : public Command +class CommandCSSetKeepModes + : public Command { public: CommandCSSetKeepModes(Module *creator, const Anope::string &cname = "chanserv/set/keepmodes") : Command(creator, cname, 2, 2) @@ -390,7 +396,8 @@ public: } }; -class CommandCSSetPeace : public Command +class CommandCSSetPeace + : public Command { public: CommandCSSetPeace(Module *creator, const Anope::string &cname = "chanserv/set/peace") : Command(creator, cname, 2, 2) @@ -462,7 +469,8 @@ inline static Anope::string BotModes() ); } -class CommandCSSetPersist : public Command +class CommandCSSetPersist + : public Command { public: CommandCSSetPersist(Module *creator, const Anope::string &cname = "chanserv/set/persist") : Command(creator, cname, 2, 2) @@ -611,7 +619,8 @@ public: } }; -class CommandCSSetRestricted : public Command +class CommandCSSetRestricted + : public Command { public: CommandCSSetRestricted(Module *creator, const Anope::string &cname = "chanserv/set/restricted") : Command(creator, cname, 2, 2) @@ -673,7 +682,8 @@ public: } }; -class CommandCSSetSecure : public Command +class CommandCSSetSecure + : public Command { public: CommandCSSetSecure(Module *creator, const Anope::string &cname = "chanserv/set/secure") : Command(creator, cname, 2, 2) @@ -736,7 +746,8 @@ public: } }; -class CommandCSSetSecureFounder : public Command +class CommandCSSetSecureFounder + : public Command { public: CommandCSSetSecureFounder(Module *creator, const Anope::string &cname = "chanserv/set/securefounder") : Command(creator, cname, 2, 2) @@ -800,7 +811,8 @@ public: } }; -class CommandCSSetSecureOps : public Command +class CommandCSSetSecureOps + : public Command { public: CommandCSSetSecureOps(Module *creator, const Anope::string &cname = "chanserv/set/secureops") : Command(creator, cname, 2, 2) @@ -862,7 +874,8 @@ public: } }; -class CommandCSSetSignKick : public Command +class CommandCSSetSignKick + : public Command { public: CommandCSSetSignKick(Module *creator, const Anope::string &cname = "chanserv/set/signkick") : Command(creator, cname, 2, 2) @@ -939,7 +952,8 @@ public: } }; -class CommandCSSetSuccessor : public Command +class CommandCSSetSuccessor + : public Command { public: CommandCSSetSuccessor(Module *creator, const Anope::string &cname = "chanserv/set/successor") : Command(creator, cname, 1, 2) @@ -1033,7 +1047,8 @@ public: } }; -class CommandCSSetNoexpire : public Command +class CommandCSSetNoexpire + : public Command { public: CommandCSSetNoexpire(Module *creator) : Command(creator, "chanserv/saset/noexpire", 2, 2) @@ -1091,13 +1106,15 @@ public: } }; -class CSSet : public Module +class CSSet + : public Module { SerializableExtensibleItem<bool> noautoop, peace, securefounder, restricted, secure, secureops, signkick, signkick_level, noexpire, persist; - struct KeepModes : SerializableExtensibleItem<bool> + struct KeepModes + : SerializableExtensibleItem<bool> { KeepModes(Module *m, const Anope::string &n) : SerializableExtensibleItem<bool>(m, n) { } diff --git a/modules/commands/cs_set_misc.cpp b/modules/commands/cs_set_misc.cpp index 5bcdd748e..7a8030d57 100644 --- a/modules/commands/cs_set_misc.cpp +++ b/modules/commands/cs_set_misc.cpp @@ -31,7 +31,9 @@ static ExtensibleItem<CSMiscData> *GetItem(const Anope::string &name) return it; } -struct CSMiscData : MiscData, Serializable +struct CSMiscData + : MiscData + , Serializable { CSMiscData(Extensible *obj) : Serializable("CSMiscData") { } @@ -88,7 +90,8 @@ static Anope::string GetAttribute(const Anope::string &command) return command; } -class CommandCSSetMisc : public Command +class CommandCSSetMisc + : public Command { public: CommandCSSetMisc(Module *creator, const Anope::string &cname = "chanserv/set/misc") : Command(creator, cname, 1, 2) @@ -164,7 +167,8 @@ public: } }; -class CSSetMisc : public Module +class CSSetMisc + : public Module { CommandCSSetMisc commandcssetmisc; Serialize::Type csmiscdata_type; diff --git a/modules/commands/cs_status.cpp b/modules/commands/cs_status.cpp index 1ae0dcc39..492e30a49 100644 --- a/modules/commands/cs_status.cpp +++ b/modules/commands/cs_status.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandCSStatus : public Command +class CommandCSStatus + : public Command { public: CommandCSStatus(Module *creator) : Command(creator, "chanserv/status", 1, 2) @@ -110,7 +111,8 @@ public: } }; -class CSStatus : public Module +class CSStatus + : public Module { CommandCSStatus commandcsstatus; diff --git a/modules/commands/cs_suspend.cpp b/modules/commands/cs_suspend.cpp index dccad5a5f..6d5322753 100644 --- a/modules/commands/cs_suspend.cpp +++ b/modules/commands/cs_suspend.cpp @@ -12,7 +12,9 @@ #include "module.h" #include "modules/suspend.h" -struct CSSuspendInfo : SuspendInfo, Serializable +struct CSSuspendInfo + : SuspendInfo + , Serializable { CSSuspendInfo(Extensible *) : Serializable("CSSuspendInfo") { } @@ -50,7 +52,8 @@ struct CSSuspendInfo : SuspendInfo, Serializable } }; -class CommandCSSuspend : public Command +class CommandCSSuspend + : public Command { public: CommandCSSuspend(Module *creator) : Command(creator, "chanserv/suspend", 2, 3) @@ -142,7 +145,8 @@ public: } }; -class CommandCSUnSuspend : public Command +class CommandCSUnSuspend + : public Command { public: CommandCSUnSuspend(Module *creator) : Command(creator, "chanserv/unsuspend", 1, 1) @@ -193,7 +197,8 @@ public: } }; -class CSSuspend : public Module +class CSSuspend + : public Module { CommandCSSuspend commandcssuspend; CommandCSUnSuspend commandcsunsuspend; diff --git a/modules/commands/cs_sync.cpp b/modules/commands/cs_sync.cpp index cafb73406..7a7140944 100644 --- a/modules/commands/cs_sync.cpp +++ b/modules/commands/cs_sync.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandCSSync : public Command +class CommandCSSync + : public Command { public: CommandCSSync(Module *creator) : Command(creator, "chanserv/sync", 1, 1) @@ -52,7 +53,8 @@ public: } }; -class CSSync : public Module +class CSSync + : public Module { CommandCSSync commandcssync; public: diff --git a/modules/commands/cs_topic.cpp b/modules/commands/cs_topic.cpp index 24bf7ce17..582c6a1e7 100644 --- a/modules/commands/cs_topic.cpp +++ b/modules/commands/cs_topic.cpp @@ -12,7 +12,8 @@ #include "module.h" #include "modules/cs_mode.h" -class CommandCSSetKeepTopic : public Command +class CommandCSSetKeepTopic + : public Command { public: CommandCSSetKeepTopic(Module *creator, const Anope::string &cname = "chanserv/set/keeptopic") : Command(creator, cname, 2, 2) @@ -76,7 +77,8 @@ public: } }; -class CommandCSTopic : public Command +class CommandCSTopic + : public Command { ExtensibleRef<bool> topiclock; @@ -202,7 +204,8 @@ public: } }; -class CSTopic : public Module +class CSTopic + : public Module { CommandCSTopic commandcstopic; CommandCSSetKeepTopic commandcssetkeeptopic; diff --git a/modules/commands/cs_unban.cpp b/modules/commands/cs_unban.cpp index 402dfe807..763af5533 100644 --- a/modules/commands/cs_unban.cpp +++ b/modules/commands/cs_unban.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandCSUnban : public Command +class CommandCSUnban + : public Command { public: CommandCSUnban(Module *creator) : Command(creator, "chanserv/unban", 0, 2) @@ -115,7 +116,8 @@ public: } }; -class CSUnban : public Module +class CSUnban + : public Module { CommandCSUnban commandcsunban; diff --git a/modules/commands/cs_updown.cpp b/modules/commands/cs_updown.cpp index 3cbd15ed1..90bb882e2 100644 --- a/modules/commands/cs_updown.cpp +++ b/modules/commands/cs_updown.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandCSUp : public Command +class CommandCSUp + : public Command { void SetModes(User *u, Channel *c) { @@ -129,7 +130,8 @@ public: } }; -class CommandCSDown : public Command +class CommandCSDown + : public Command { void RemoveAll(User *u, Channel *c) { @@ -226,7 +228,8 @@ public: } }; -class CSUpDown : public Module +class CSUpDown + : public Module { CommandCSUp commandcsup; CommandCSDown commandcsdown; diff --git a/modules/commands/cs_xop.cpp b/modules/commands/cs_xop.cpp index 107b86151..7b0b8fd0c 100644 --- a/modules/commands/cs_xop.cpp +++ b/modules/commands/cs_xop.cpp @@ -17,7 +17,8 @@ namespace std::map<Anope::string, std::vector<Anope::string> > permissions; } -class XOPChanAccess : public ChanAccess +class XOPChanAccess + : public ChanAccess { public: Anope::string type; @@ -84,7 +85,8 @@ public: } }; -class XOPAccessProvider : public AccessProvider +class XOPAccessProvider + : public AccessProvider { public: XOPAccessProvider(Module *o) : AccessProvider(o, "access/xop") @@ -97,7 +99,8 @@ public: } }; -class CommandCSXOP : public Command +class CommandCSXOP + : public Command { private: void DoAdd(CommandSource &source, ChannelInfo *ci, const std::vector<Anope::string> ¶ms) @@ -291,7 +294,8 @@ private: /* Special case: is it a number/list? Only do search if it isn't. */ if (isdigit(mask[0]) && mask.find_first_not_of("1234567890,-") == Anope::string::npos) { - class XOPDelCallback : public NumberList + class XOPDelCallback + : public NumberList { CommandSource &source; ChannelInfo *ci; @@ -394,7 +398,8 @@ private: if (!nick.empty() && nick.find_first_not_of("1234567890,-") == Anope::string::npos) { - class XOPListCallback : public NumberList + class XOPListCallback + : public NumberList { ListFormatter &list; ChannelInfo *ci; @@ -595,7 +600,8 @@ public: } }; -class CSXOP : public Module +class CSXOP + : public Module { XOPAccessProvider accessprovider; CommandCSXOP commandcsxop; diff --git a/modules/commands/gl_global.cpp b/modules/commands/gl_global.cpp index 18814b738..3bea27e4d 100644 --- a/modules/commands/gl_global.cpp +++ b/modules/commands/gl_global.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandGLGlobal : public Command +class CommandGLGlobal + : public Command { ServiceReference<GlobalService> GService; @@ -51,7 +52,8 @@ public: } }; -class GLGlobal : public Module +class GLGlobal + : public Module { CommandGLGlobal commandglglobal; diff --git a/modules/commands/greet.cpp b/modules/commands/greet.cpp index 6cbb24464..81a5e9c6d 100644 --- a/modules/commands/greet.cpp +++ b/modules/commands/greet.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandBSSetGreet : public Command +class CommandBSSetGreet + : public Command { public: CommandBSSetGreet(Module *creator, const Anope::string &sname = "botserv/set/greet") : Command(creator, sname, 2, 2) @@ -75,7 +76,8 @@ public: } }; -class CommandNSSetGreet : public Command +class CommandNSSetGreet + : public Command { public: CommandNSSetGreet(Module *creator, const Anope::string &sname = "nickserv/set/greet", size_t min = 0) : Command(creator, sname, min, min + 1) @@ -136,7 +138,8 @@ public: } }; -class CommandNSSASetGreet : public CommandNSSetGreet +class CommandNSSASetGreet + : public CommandNSSetGreet { public: CommandNSSASetGreet(Module *creator) : CommandNSSetGreet(creator, "nickserv/saset/greet", 1) @@ -162,7 +165,8 @@ public: } }; -class Greet : public Module +class Greet + : public Module { /* channel setting for whether or not greet should be shown */ SerializableExtensibleItem<bool> bs_greet; diff --git a/modules/commands/help.cpp b/modules/commands/help.cpp index 3e8b87c0e..3d6dc47c3 100644 --- a/modules/commands/help.cpp +++ b/modules/commands/help.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandHelp : public Command +class CommandHelp + : public Command { static const unsigned help_wrap_len = 40; @@ -182,7 +183,8 @@ public: } }; -class Help : public Module +class Help + : public Module { CommandHelp commandhelp; diff --git a/modules/commands/hs_del.cpp b/modules/commands/hs_del.cpp index 25e5e7d0b..81fcf3e68 100644 --- a/modules/commands/hs_del.cpp +++ b/modules/commands/hs_del.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandHSDel : public Command +class CommandHSDel + : public Command { public: CommandHSDel(Module *creator) : Command(creator, "hostserv/del", 1, 1) @@ -51,7 +52,8 @@ public: } }; -class CommandHSDelAll : public Command +class CommandHSDelAll + : public Command { public: CommandHSDelAll(Module *creator) : Command(creator, "hostserv/delall", 1, 1) @@ -96,7 +98,8 @@ public: } }; -class HSDel : public Module +class HSDel + : public Module { CommandHSDel commandhsdel; CommandHSDelAll commandhsdelall; diff --git a/modules/commands/hs_group.cpp b/modules/commands/hs_group.cpp index 4d6e802dc..c05c467c0 100644 --- a/modules/commands/hs_group.cpp +++ b/modules/commands/hs_group.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandHSGroup : public Command +class CommandHSGroup + : public Command { bool setting = false; @@ -75,7 +76,8 @@ public: } }; -class HSGroup : public Module +class HSGroup + : public Module { CommandHSGroup commandhsgroup; bool syncongroup; diff --git a/modules/commands/hs_list.cpp b/modules/commands/hs_list.cpp index 9b1a168be..bacd4b367 100644 --- a/modules/commands/hs_list.cpp +++ b/modules/commands/hs_list.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandHSList : public Command +class CommandHSList + : public Command { public: CommandHSList(Module *creator) : Command(creator, "hostserv/list", 0, 1) @@ -142,7 +143,8 @@ public: } }; -class HSList : public Module +class HSList + : public Module { CommandHSList commandhslist; diff --git a/modules/commands/hs_off.cpp b/modules/commands/hs_off.cpp index 053a381b1..cb65c7035 100644 --- a/modules/commands/hs_off.cpp +++ b/modules/commands/hs_off.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandHSOff : public Command +class CommandHSOff + : public Command { public: CommandHSOff(Module *creator) : Command(creator, "hostserv/off", 0, 0) @@ -53,7 +54,8 @@ public: } }; -class HSOff : public Module +class HSOff + : public Module { CommandHSOff commandhsoff; diff --git a/modules/commands/hs_on.cpp b/modules/commands/hs_on.cpp index 7c61fe537..7f14e3406 100644 --- a/modules/commands/hs_on.cpp +++ b/modules/commands/hs_on.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandHSOn : public Command +class CommandHSOn + : public Command { public: CommandHSOn(Module *creator) : Command(creator, "hostserv/on", 0, 0) @@ -59,7 +60,8 @@ public: } }; -class HSOn : public Module +class HSOn + : public Module { CommandHSOn commandhson; diff --git a/modules/commands/hs_request.cpp b/modules/commands/hs_request.cpp index 8e63f2b9d..361e4a8f7 100644 --- a/modules/commands/hs_request.cpp +++ b/modules/commands/hs_request.cpp @@ -20,7 +20,8 @@ static ServiceReference<MemoServService> memoserv("MemoServService", "MemoServ") static void req_send_memos(Module *me, CommandSource &source, const Anope::string &vIdent, const Anope::string &vHost); -struct HostRequest : Serializable +struct HostRequest + : Serializable { Anope::string nick; Anope::string ident; @@ -63,7 +64,8 @@ struct HostRequest : Serializable } }; -class CommandHSRequest : public Command +class CommandHSRequest + : public Command { bool isvalidchar(char c) { @@ -185,7 +187,8 @@ public: } }; -class CommandHSActivate : public Command +class CommandHSActivate + : public Command { public: CommandHSActivate(Module *creator) : Command(creator, "hostserv/activate", 1, 1) @@ -234,7 +237,8 @@ public: } }; -class CommandHSReject : public Command +class CommandHSReject + : public Command { public: CommandHSReject(Module *creator) : Command(creator, "hostserv/reject", 1, 2) @@ -290,7 +294,8 @@ public: } }; -class CommandHSWaiting : public Command +class CommandHSWaiting + : public Command { public: CommandHSWaiting(Module *creator) : Command(creator, "hostserv/waiting", 0, 0) @@ -348,7 +353,8 @@ public: } }; -class HSRequest : public Module +class HSRequest + : public Module { CommandHSRequest commandhsrequest; CommandHSActivate commandhsactive; diff --git a/modules/commands/hs_set.cpp b/modules/commands/hs_set.cpp index 4e896a964..8c2027305 100644 --- a/modules/commands/hs_set.cpp +++ b/modules/commands/hs_set.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandHSSet : public Command +class CommandHSSet + : public Command { public: CommandHSSet(Module *creator) : Command(creator, "hostserv/set", 2, 2) @@ -104,7 +105,8 @@ public: } }; -class CommandHSSetAll : public Command +class CommandHSSetAll + : public Command { void Sync(const NickAlias *na) { @@ -212,7 +214,8 @@ public: } }; -class HSSet : public Module +class HSSet + : public Module { CommandHSSet commandhsset; CommandHSSetAll commandhssetall; diff --git a/modules/commands/ms_cancel.cpp b/modules/commands/ms_cancel.cpp index b877d0588..b7b6dee2f 100644 --- a/modules/commands/ms_cancel.cpp +++ b/modules/commands/ms_cancel.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandMSCancel : public Command +class CommandMSCancel + : public Command { public: CommandMSCancel(Module *creator) : Command(creator, "memoserv/cancel", 1, 1) @@ -87,7 +88,8 @@ public: } }; -class MSCancel : public Module +class MSCancel + : public Module { CommandMSCancel commandmscancel; diff --git a/modules/commands/ms_check.cpp b/modules/commands/ms_check.cpp index de26adee8..be5e7fc56 100644 --- a/modules/commands/ms_check.cpp +++ b/modules/commands/ms_check.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandMSCheck : public Command +class CommandMSCheck + : public Command { public: CommandMSCheck(Module *creator) : Command(creator, "memoserv/check", 1, 1) @@ -72,7 +73,8 @@ public: } }; -class MSCheck : public Module +class MSCheck + : public Module { CommandMSCheck commandmscheck; diff --git a/modules/commands/ms_del.cpp b/modules/commands/ms_del.cpp index 13f2b53d2..01e882e44 100644 --- a/modules/commands/ms_del.cpp +++ b/modules/commands/ms_del.cpp @@ -11,7 +11,8 @@ #include "module.h" -class MemoDelCallback : public NumberList +class MemoDelCallback + : public NumberList { CommandSource &source; Command *cmd; @@ -36,7 +37,8 @@ public: } }; -class CommandMSDel : public Command +class CommandMSDel + : public Command { public: CommandMSDel(Module *creator) : Command(creator, "memoserv/del", 0, 2) @@ -144,7 +146,8 @@ public: } }; -class MSDel : public Module +class MSDel + : public Module { CommandMSDel commandmsdel; diff --git a/modules/commands/ms_ignore.cpp b/modules/commands/ms_ignore.cpp index b4da89785..a1d2d6dc3 100644 --- a/modules/commands/ms_ignore.cpp +++ b/modules/commands/ms_ignore.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandMSIgnore : public Command +class CommandMSIgnore + : public Command { public: CommandMSIgnore(Module *creator) : Command(creator, "memoserv/ignore", 1, 3) @@ -118,7 +119,8 @@ public: } }; -class MSIgnore : public Module +class MSIgnore + : public Module { CommandMSIgnore commandmsignore; diff --git a/modules/commands/ms_info.cpp b/modules/commands/ms_info.cpp index b8b44085b..adeb5d082 100644 --- a/modules/commands/ms_info.cpp +++ b/modules/commands/ms_info.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandMSInfo : public Command +class CommandMSInfo + : public Command { public: CommandMSInfo(Module *creator) : Command(creator, "memoserv/info", 0, 1) @@ -218,7 +219,8 @@ public: } }; -class MSInfo : public Module +class MSInfo + : public Module { CommandMSInfo commandmsinfo; diff --git a/modules/commands/ms_list.cpp b/modules/commands/ms_list.cpp index e1bf738fa..b527939c6 100644 --- a/modules/commands/ms_list.cpp +++ b/modules/commands/ms_list.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandMSList : public Command +class CommandMSList + : public Command { public: CommandMSList(Module *creator) : Command(creator, "memoserv/list", 0, 2) @@ -65,7 +66,8 @@ public: if (!param.empty() && isdigit(param[0])) { - class MemoListCallback : public NumberList + class MemoListCallback + : public NumberList { ListFormatter &list; CommandSource &source; @@ -149,7 +151,8 @@ public: } }; -class MSList : public Module +class MSList + : public Module { CommandMSList commandmslist; diff --git a/modules/commands/ms_read.cpp b/modules/commands/ms_read.cpp index a8676a8f5..496bf38a7 100644 --- a/modules/commands/ms_read.cpp +++ b/modules/commands/ms_read.cpp @@ -47,7 +47,8 @@ static void rsend_notify(CommandSource &source, MemoInfo *mi, Memo *m, const Ano m->receipt = false; } -class MemoListCallback : public NumberList +class MemoListCallback + : public NumberList { CommandSource &source; MemoInfo *mi; @@ -104,7 +105,8 @@ public: } }; -class CommandMSRead : public Command +class CommandMSRead + : public Command { public: CommandMSRead(Module *creator) : Command(creator, "memoserv/read", 1, 2) @@ -209,7 +211,8 @@ public: } }; -class MSRead : public Module +class MSRead + : public Module { CommandMSRead commandmsread; diff --git a/modules/commands/ms_rsend.cpp b/modules/commands/ms_rsend.cpp index 854b4e2be..092a0ea34 100644 --- a/modules/commands/ms_rsend.cpp +++ b/modules/commands/ms_rsend.cpp @@ -16,7 +16,8 @@ namespace ServiceReference<MemoServService> memoserv("MemoServService", "MemoServ"); } -class CommandMSRSend : public Command +class CommandMSRSend + : public Command { public: CommandMSRSend(Module *creator) : Command(creator, "memoserv/rsend", 2, 2) @@ -88,7 +89,8 @@ public: } }; -class MSRSend : public Module +class MSRSend + : public Module { CommandMSRSend commandmsrsend; diff --git a/modules/commands/ms_send.cpp b/modules/commands/ms_send.cpp index 141cca01f..ced13bb6f 100644 --- a/modules/commands/ms_send.cpp +++ b/modules/commands/ms_send.cpp @@ -16,7 +16,8 @@ namespace ServiceReference<MemoServService> memoserv("MemoServService", "MemoServ"); } -class CommandMSSend : public Command +class CommandMSSend + : public Command { public: CommandMSSend(Module *creator) : Command(creator, "memoserv/send", 2, 2) @@ -71,7 +72,8 @@ public: } }; -class MSSend : public Module +class MSSend + : public Module { CommandMSSend commandmssend; diff --git a/modules/commands/ms_sendall.cpp b/modules/commands/ms_sendall.cpp index dfbc4c40c..a7bdb5d93 100644 --- a/modules/commands/ms_sendall.cpp +++ b/modules/commands/ms_sendall.cpp @@ -16,7 +16,8 @@ namespace ServiceReference<MemoServService> memoserv("MemoServService", "MemoServ"); } -class CommandMSSendAll : public Command +class CommandMSSendAll + : public Command { public: CommandMSSendAll(Module *creator) : Command(creator, "memoserv/sendall", 1, 1) @@ -52,7 +53,8 @@ public: } }; -class MSSendAll : public Module +class MSSendAll + : public Module { CommandMSSendAll commandmssendall; diff --git a/modules/commands/ms_set.cpp b/modules/commands/ms_set.cpp index 946535f64..bd745a5ef 100644 --- a/modules/commands/ms_set.cpp +++ b/modules/commands/ms_set.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandMSSet : public Command +class CommandMSSet + : public Command { private: void DoNotify(CommandSource &source, const std::vector<Anope::string> ¶ms, MemoInfo *mi) @@ -298,7 +299,8 @@ public: } }; -class MSSet : public Module +class MSSet + : public Module { CommandMSSet commandmsset; SerializableExtensibleItem<bool> memo_signon, memo_receive, memo_mail, memo_hardmax; diff --git a/modules/commands/ms_staff.cpp b/modules/commands/ms_staff.cpp index fb5d9afd8..0930bbecb 100644 --- a/modules/commands/ms_staff.cpp +++ b/modules/commands/ms_staff.cpp @@ -16,7 +16,8 @@ namespace ServiceReference<MemoServService> memoserv("MemoServService", "MemoServ"); } -class CommandMSStaff : public Command +class CommandMSStaff + : public Command { public: CommandMSStaff(Module *creator) : Command(creator, "memoserv/staff", 1, 1) @@ -49,7 +50,8 @@ public: } }; -class MSStaff : public Module +class MSStaff + : public Module { CommandMSStaff commandmsstaff; diff --git a/modules/commands/ns_access.cpp b/modules/commands/ns_access.cpp index a66959f32..0b42436e4 100644 --- a/modules/commands/ns_access.cpp +++ b/modules/commands/ns_access.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandNSAccess : public Command +class CommandNSAccess + : public Command { private: void DoAdd(CommandSource &source, NickCore *nc, const Anope::string &mask) @@ -186,7 +187,8 @@ public: } }; -class NSAccess : public Module +class NSAccess + : public Module { CommandNSAccess commandnsaccess; diff --git a/modules/commands/ns_ajoin.cpp b/modules/commands/ns_ajoin.cpp index 9b63d6576..f28b1d0a1 100644 --- a/modules/commands/ns_ajoin.cpp +++ b/modules/commands/ns_ajoin.cpp @@ -13,13 +13,15 @@ struct AJoinEntry; -struct AJoinList : Serialize::Checker<std::vector<AJoinEntry *> > +struct AJoinList + : Serialize::Checker<std::vector<AJoinEntry *> > { AJoinList(Extensible *) : Serialize::Checker<std::vector<AJoinEntry *> >("AJoinEntry") { } ~AJoinList(); }; -struct AJoinEntry : Serializable +struct AJoinEntry + : Serializable { Serialize::Reference<NickCore> owner; Anope::string channel; @@ -86,7 +88,8 @@ AJoinList::~AJoinList() delete ajoin; } -class CommandNSAJoin : public Command +class CommandNSAJoin + : public Command { void DoList(CommandSource &source, NickCore *nc) { @@ -297,7 +300,8 @@ public: } }; -class NSAJoin : public Module +class NSAJoin + : public Module { CommandNSAJoin commandnsajoin; ExtensibleItem<AJoinList> ajoinlist; diff --git a/modules/commands/ns_alist.cpp b/modules/commands/ns_alist.cpp index a2ee212b4..dc05360a4 100644 --- a/modules/commands/ns_alist.cpp +++ b/modules/commands/ns_alist.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandNSAList : public Command +class CommandNSAList + : public Command { static bool ChannelSort(ChannelInfo *ci1, ChannelInfo *ci2) { @@ -131,7 +132,8 @@ public: } }; -class NSAList : public Module +class NSAList + : public Module { CommandNSAList commandnsalist; diff --git a/modules/commands/ns_cert.cpp b/modules/commands/ns_cert.cpp index 12dc2ede9..8c874ad81 100644 --- a/modules/commands/ns_cert.cpp +++ b/modules/commands/ns_cert.cpp @@ -14,7 +14,8 @@ static Anope::hash_map<NickCore *> certmap; -struct CertServiceImpl : CertService +struct CertServiceImpl + : CertService { CertServiceImpl(Module *o) : CertService(o) { } @@ -27,7 +28,8 @@ struct CertServiceImpl : CertService } }; -struct NSCertListImpl : NSCertList +struct NSCertListImpl + : NSCertList { Serialize::Reference<NickCore> nc; std::vector<Anope::string> certs; @@ -119,7 +121,8 @@ public: nc->Shrink<NSCertList>("certificates"); } - struct ExtensibleItem : ::ExtensibleItem<NSCertListImpl> + struct ExtensibleItem + : ::ExtensibleItem<NSCertListImpl> { ExtensibleItem(Module *m, const Anope::string &ename) : ::ExtensibleItem<NSCertListImpl>(m, ename) { } @@ -160,7 +163,8 @@ public: }; }; -class CommandNSCert : public Command +class CommandNSCert + : public Command { private: void DoAdd(CommandSource &source, NickCore *nc, Anope::string certfp) @@ -338,7 +342,8 @@ public: } }; -class NSCert : public Module +class NSCert + : public Module { CommandNSCert commandnscert; NSCertListImpl::ExtensibleItem certs; diff --git a/modules/commands/ns_drop.cpp b/modules/commands/ns_drop.cpp index c088d88fc..d69486e8a 100644 --- a/modules/commands/ns_drop.cpp +++ b/modules/commands/ns_drop.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandNSDrop : public Command +class CommandNSDrop + : public Command { public: CommandNSDrop(Module *creator) : Command(creator, "nickserv/drop", 1, 1) @@ -71,7 +72,8 @@ public: } }; -class NSDrop : public Module +class NSDrop + : public Module { CommandNSDrop commandnsdrop; diff --git a/modules/commands/ns_getemail.cpp b/modules/commands/ns_getemail.cpp index e69b7a2a1..d3c18c0cf 100644 --- a/modules/commands/ns_getemail.cpp +++ b/modules/commands/ns_getemail.cpp @@ -15,7 +15,8 @@ #include "module.h" -class CommandNSGetEMail : public Command +class CommandNSGetEMail + : public Command { public: CommandNSGetEMail(Module *creator) : Command(creator, "nickserv/getemail", 1, 1) @@ -58,7 +59,8 @@ public: } }; -class NSGetEMail : public Module +class NSGetEMail + : public Module { CommandNSGetEMail commandnsgetemail; public: diff --git a/modules/commands/ns_group.cpp b/modules/commands/ns_group.cpp index 6f45d7f49..96a70fdd6 100644 --- a/modules/commands/ns_group.cpp +++ b/modules/commands/ns_group.cpp @@ -12,7 +12,8 @@ #include "module.h" #include "modules/ns_cert.h" -class NSGroupRequest : public IdentifyRequest +class NSGroupRequest + : public IdentifyRequest { CommandSource source; Command *cmd; @@ -83,7 +84,8 @@ public: } }; -class CommandNSGroup : public Command +class CommandNSGroup + : public Command { public: CommandNSGroup(Module *creator) : Command(creator, "nickserv/group", 0, 2) @@ -228,7 +230,8 @@ public: } }; -class CommandNSUngroup : public Command +class CommandNSUngroup + : public Command { public: CommandNSUngroup(Module *creator) : Command(creator, "nickserv/ungroup", 0, 1) @@ -291,7 +294,8 @@ public: } }; -class CommandNSGList : public Command +class CommandNSGList + : public Command { public: CommandNSGList(Module *creator) : Command(creator, "nickserv/glist", 0, 1) @@ -376,7 +380,8 @@ public: } }; -class NSGroup : public Module +class NSGroup + : public Module { CommandNSGroup commandnsgroup; CommandNSUngroup commandnsungroup; diff --git a/modules/commands/ns_identify.cpp b/modules/commands/ns_identify.cpp index ebe8fbfe1..1f9c49eab 100644 --- a/modules/commands/ns_identify.cpp +++ b/modules/commands/ns_identify.cpp @@ -11,7 +11,8 @@ #include "module.h" -class NSIdentifyRequest : public IdentifyRequest +class NSIdentifyRequest + : public IdentifyRequest { CommandSource source; Command *cmd; @@ -57,7 +58,8 @@ public: } }; -class CommandNSIdentify : public Command +class CommandNSIdentify + : public Command { public: CommandNSIdentify(Module *creator) : Command(creator, "nickserv/identify", 1, 2) @@ -113,7 +115,8 @@ public: } }; -class NSIdentify : public Module +class NSIdentify + : public Module { CommandNSIdentify commandnsidentify; diff --git a/modules/commands/ns_info.cpp b/modules/commands/ns_info.cpp index 567d095f2..10bfda6f4 100644 --- a/modules/commands/ns_info.cpp +++ b/modules/commands/ns_info.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandNSInfo : public Command +class CommandNSInfo + : public Command { public: CommandNSInfo(Module *creator) : Command(creator, "nickserv/info", 0, 2) @@ -134,7 +135,8 @@ public: }; -class CommandNSSetHide : public Command +class CommandNSSetHide + : public Command { public: CommandNSSetHide(Module *creator, const Anope::string &sname = "nickserv/set/hide", size_t min = 2) : Command(creator, sname, min, min + 1) @@ -232,7 +234,8 @@ public: } }; -class CommandNSSASetHide : public CommandNSSetHide +class CommandNSSASetHide + : public CommandNSSetHide { public: CommandNSSASetHide(Module *creator) : CommandNSSetHide(creator, "nickserv/saset/hide", 3) @@ -261,7 +264,8 @@ public: } }; -class NSInfo : public Module +class NSInfo + : public Module { CommandNSInfo commandnsinfo; diff --git a/modules/commands/ns_list.cpp b/modules/commands/ns_list.cpp index ed72c27f2..f32cad2f5 100644 --- a/modules/commands/ns_list.cpp +++ b/modules/commands/ns_list.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandNSList : public Command +class CommandNSList + : public Command { public: CommandNSList(Module *creator) : Command(creator, "nickserv/list", 1, 2) @@ -176,7 +177,8 @@ public: }; -class CommandNSSetPrivate : public Command +class CommandNSSetPrivate + : public Command { public: CommandNSSetPrivate(Module *creator, const Anope::string &sname = "nickserv/set/private", size_t min = 1) : Command(creator, sname, min, min + 1) @@ -241,7 +243,8 @@ public: } }; -class CommandNSSASetPrivate : public CommandNSSetPrivate +class CommandNSSASetPrivate + : public CommandNSSetPrivate { public: CommandNSSASetPrivate(Module *creator) : CommandNSSetPrivate(creator, "nickserv/saset/private", 2) @@ -270,7 +273,8 @@ public: }; -class NSList : public Module +class NSList + : public Module { CommandNSList commandnslist; diff --git a/modules/commands/ns_logout.cpp b/modules/commands/ns_logout.cpp index ae775ea0d..7a273f08c 100644 --- a/modules/commands/ns_logout.cpp +++ b/modules/commands/ns_logout.cpp @@ -13,7 +13,8 @@ static ServiceReference<NickServService> NickServService("NickServService", "NickServ"); -class CommandNSLogout : public Command +class CommandNSLogout + : public Command { public: CommandNSLogout(Module *creator) : Command(creator, "nickserv/logout", 0, 2) @@ -76,7 +77,8 @@ public: } }; -class NSLogout : public Module +class NSLogout + : public Module { CommandNSLogout commandnslogout; diff --git a/modules/commands/ns_recover.cpp b/modules/commands/ns_recover.cpp index 7836949a6..52c58d841 100644 --- a/modules/commands/ns_recover.cpp +++ b/modules/commands/ns_recover.cpp @@ -23,7 +23,8 @@ public: Anope::string to; }; -class NSRecoverRequest : public IdentifyRequest +class NSRecoverRequest + : public IdentifyRequest { CommandSource source; Command *cmd; @@ -141,7 +142,8 @@ public: } }; -class CommandNSRecover : public Command +class CommandNSRecover + : public Command { public: CommandNSRecover(Module *creator) : Command(creator, "nickserv/recover", 1, 2) @@ -221,7 +223,8 @@ public: } }; -class NSRecover : public Module +class NSRecover + : public Module { CommandNSRecover commandnsrecover; PrimitiveExtensibleItem<NSRecoverInfo> recover; diff --git a/modules/commands/ns_register.cpp b/modules/commands/ns_register.cpp index a5281b4be..a597a9c13 100644 --- a/modules/commands/ns_register.cpp +++ b/modules/commands/ns_register.cpp @@ -13,7 +13,8 @@ static bool SendRegmail(User *u, const NickAlias *na, BotInfo *bi); -class CommandNSConfirm : public Command +class CommandNSConfirm + : public Command { public: CommandNSConfirm(Module *creator) : Command(creator, "nickserv/confirm", 1, 2) @@ -114,7 +115,8 @@ public: } }; -class CommandNSRegister : public Command +class CommandNSRegister + : public Command { public: CommandNSRegister(Module *creator) : Command(creator, "nickserv/register", 1, 2) @@ -309,7 +311,8 @@ public: } }; -class CommandNSResend : public Command +class CommandNSResend + : public Command { public: CommandNSResend(Module *creator) : Command(creator, "nickserv/resend", 0, 0) @@ -366,7 +369,8 @@ public: } }; -class NSRegister : public Module +class NSRegister + : public Module { CommandNSRegister commandnsregister; CommandNSConfirm commandnsconfirm; diff --git a/modules/commands/ns_resetpass.cpp b/modules/commands/ns_resetpass.cpp index 77f36bf12..73759a251 100644 --- a/modules/commands/ns_resetpass.cpp +++ b/modules/commands/ns_resetpass.cpp @@ -13,7 +13,8 @@ static bool SendResetEmail(User *u, const NickAlias *na, BotInfo *bi); -class CommandNSResetPass : public Command +class CommandNSResetPass + : public Command { public: CommandNSResetPass(Module *creator) : Command(creator, "nickserv/resetpass", 2, 2) @@ -60,7 +61,8 @@ struct ResetInfo time_t time; }; -class NSResetPass : public Module +class NSResetPass + : public Module { CommandNSResetPass commandnsresetpass; PrimitiveExtensibleItem<ResetInfo> reset; diff --git a/modules/commands/ns_set.cpp b/modules/commands/ns_set.cpp index ee4dd45b5..e6e7486c6 100644 --- a/modules/commands/ns_set.cpp +++ b/modules/commands/ns_set.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandNSSet : public Command +class CommandNSSet + : public Command { public: CommandNSSet(Module *creator) : Command(creator, "nickserv/set", 1, 3) @@ -63,7 +64,8 @@ public: } }; -class CommandNSSASet : public Command +class CommandNSSASet + : public Command { public: CommandNSSASet(Module *creator) : Command(creator, "nickserv/saset", 2, 4) @@ -105,7 +107,8 @@ public: } }; -class CommandNSSetPassword : public Command +class CommandNSSetPassword + : public Command { public: CommandNSSetPassword(Module *creator) : Command(creator, "nickserv/set/password", 1) @@ -161,7 +164,8 @@ public: } }; -class CommandNSSASetPassword : public Command +class CommandNSSASetPassword + : public Command { public: CommandNSSASetPassword(Module *creator) : Command(creator, "nickserv/saset/password", 2, 2) @@ -230,7 +234,8 @@ public: } }; -class CommandNSSetAutoOp : public Command +class CommandNSSetAutoOp + : public Command { public: CommandNSSetAutoOp(Module *creator, const Anope::string &sname = "nickserv/set/autoop", size_t min = 1) : Command(creator, sname, min, min + 1) @@ -294,7 +299,8 @@ public: } }; -class CommandNSSASetAutoOp : public CommandNSSetAutoOp +class CommandNSSASetAutoOp + : public CommandNSSetAutoOp { public: CommandNSSASetAutoOp(Module *creator) : CommandNSSetAutoOp(creator, "nickserv/saset/autoop", 2) @@ -322,7 +328,8 @@ public: } }; -class CommandNSSetNeverOp : public Command +class CommandNSSetNeverOp + : public Command { public: CommandNSSetNeverOp(Module *creator, const Anope::string &sname = "nickserv/set/neverop", size_t min = 1) : Command(creator, sname, min, min + 1) @@ -382,7 +389,8 @@ public: } }; -class CommandNSSASetNeverOp : public CommandNSSetNeverOp +class CommandNSSASetNeverOp + : public CommandNSSetNeverOp { public: CommandNSSASetNeverOp(Module *creator) : CommandNSSetNeverOp(creator, "nickserv/saset/neverop", 2) @@ -405,7 +413,8 @@ public: } }; -class CommandNSSetDisplay : public Command +class CommandNSSetDisplay + : public Command { public: CommandNSSetDisplay(Module *creator, const Anope::string &sname = "nickserv/set/display", size_t min = 1) : Command(creator, sname, min, min + 1) @@ -474,7 +483,8 @@ public: } }; -class CommandNSSASetDisplay : public CommandNSSetDisplay +class CommandNSSASetDisplay + : public CommandNSSetDisplay { public: CommandNSSASetDisplay(Module *creator) : CommandNSSetDisplay(creator, "nickserv/saset/display", 2) @@ -498,7 +508,8 @@ public: } }; -class CommandNSSetEmail : public Command +class CommandNSSetEmail + : public Command { static bool SendConfirmMail(User *u, NickCore *nc, BotInfo *bi, const Anope::string &new_email) { @@ -621,7 +632,8 @@ public: } }; -class CommandNSSASetEmail : public CommandNSSetEmail +class CommandNSSASetEmail + : public CommandNSSetEmail { public: CommandNSSASetEmail(Module *creator) : CommandNSSetEmail(creator, "nickserv/saset/email", 2) @@ -644,7 +656,8 @@ public: } }; -class CommandNSSetKeepModes : public Command +class CommandNSSetKeepModes + : public Command { public: CommandNSSetKeepModes(Module *creator, const Anope::string &sname = "nickserv/set/keepmodes", size_t min = 1) : Command(creator, sname, min, min + 1) @@ -706,7 +719,8 @@ public: } }; -class CommandNSSASetKeepModes : public CommandNSSetKeepModes +class CommandNSSASetKeepModes + : public CommandNSSetKeepModes { public: CommandNSSASetKeepModes(Module *creator) : CommandNSSetKeepModes(creator, "nickserv/saset/keepmodes", 2) @@ -731,7 +745,8 @@ public: } }; -class CommandNSSetKill : public Command +class CommandNSSetKill + : public Command { public: CommandNSSetKill(Module *creator, const Anope::string &sname = "nickserv/set/kill", size_t min = 1) : Command(creator, sname, min, min + 1) @@ -835,7 +850,8 @@ public: } }; -class CommandNSSASetKill : public CommandNSSetKill +class CommandNSSASetKill + : public CommandNSSetKill { public: CommandNSSASetKill(Module *creator) : CommandNSSetKill(creator, "nickserv/saset/kill", 2) @@ -869,7 +885,8 @@ public: } }; -class CommandNSSetLanguage : public Command +class CommandNSSetLanguage + : public Command { public: CommandNSSetLanguage(Module *creator, const Anope::string &sname = "nickserv/set/language", size_t min = 1) : Command(creator, sname, min, min + 1) @@ -947,7 +964,8 @@ public: } }; -class CommandNSSASetLanguage : public CommandNSSetLanguage +class CommandNSSASetLanguage + : public CommandNSSetLanguage { public: CommandNSSASetLanguage(Module *creator) : CommandNSSetLanguage(creator, "nickserv/saset/language", 2) @@ -981,7 +999,8 @@ public: } }; -class CommandNSSetMessage : public Command +class CommandNSSetMessage + : public Command { public: CommandNSSetMessage(Module *creator, const Anope::string &sname = "nickserv/set/message", size_t min = 1) : Command(creator, sname, min, min + 1) @@ -1060,7 +1079,8 @@ public: } }; -class CommandNSSASetMessage : public CommandNSSetMessage +class CommandNSSASetMessage + : public CommandNSSetMessage { public: CommandNSSASetMessage(Module *creator) : CommandNSSetMessage(creator, "nickserv/saset/message", 2) @@ -1085,7 +1105,8 @@ public: } }; -class CommandNSSetSecure : public Command +class CommandNSSetSecure + : public Command { public: CommandNSSetSecure(Module *creator, const Anope::string &sname = "nickserv/set/secure", size_t min = 1) : Command(creator, sname, min, min + 1) @@ -1151,7 +1172,8 @@ public: } }; -class CommandNSSASetSecure : public CommandNSSetSecure +class CommandNSSASetSecure + : public CommandNSSetSecure { public: CommandNSSASetSecure(Module *creator) : CommandNSSetSecure(creator, "nickserv/saset/secure", 2) @@ -1180,7 +1202,8 @@ public: } }; -class CommandNSSASetNoexpire : public Command +class CommandNSSASetNoexpire + : public Command { public: CommandNSSASetNoexpire(Module *creator) : Command(creator, "nickserv/saset/noexpire", 1, 2) @@ -1232,7 +1255,8 @@ public: } }; -class NSSet : public Module +class NSSet + : public Module { CommandNSSet commandnsset; CommandNSSASet commandnssaset; @@ -1272,7 +1296,8 @@ class NSSet : public Module SerializableExtensibleItem<bool> autoop, neverop, killprotect, kill_quick, kill_immed, message, secure, noexpire; - struct KeepModes : SerializableExtensibleItem<bool> + struct KeepModes + : SerializableExtensibleItem<bool> { KeepModes(Module *m, const Anope::string &n) : SerializableExtensibleItem<bool>(m, n) { } diff --git a/modules/commands/ns_set_misc.cpp b/modules/commands/ns_set_misc.cpp index c5319f300..e6e7d8cd9 100644 --- a/modules/commands/ns_set_misc.cpp +++ b/modules/commands/ns_set_misc.cpp @@ -31,7 +31,9 @@ static ExtensibleItem<NSMiscData> *GetItem(const Anope::string &name) return it; } -struct NSMiscData : MiscData, Serializable +struct NSMiscData + : MiscData + , Serializable { NSMiscData(Extensible *) : Serializable("NSMiscData") { } @@ -88,7 +90,8 @@ static Anope::string GetAttribute(const Anope::string &command) return command; } -class CommandNSSetMisc : public Command +class CommandNSSetMisc + : public Command { public: CommandNSSetMisc(Module *creator, const Anope::string &cname = "nickserv/set/misc", size_t min = 0) : Command(creator, cname, min, min + 1) @@ -161,7 +164,8 @@ public: } }; -class CommandNSSASetMisc : public CommandNSSetMisc +class CommandNSSASetMisc + : public CommandNSSetMisc { public: CommandNSSASetMisc(Module *creator) : CommandNSSetMisc(creator, "nickserv/saset/misc", 1) @@ -176,7 +180,8 @@ public: } }; -class NSSetMisc : public Module +class NSSetMisc + : public Module { CommandNSSetMisc commandnssetmisc; CommandNSSASetMisc commandnssasetmisc; diff --git a/modules/commands/ns_status.cpp b/modules/commands/ns_status.cpp index be10a0017..94a073e22 100644 --- a/modules/commands/ns_status.cpp +++ b/modules/commands/ns_status.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandNSStatus : public Command +class CommandNSStatus + : public Command { public: CommandNSStatus(Module *creator) : Command(creator, "nickserv/status", 0, 16) @@ -72,7 +73,8 @@ public: } }; -class NSStatus : public Module +class NSStatus + : public Module { CommandNSStatus commandnsstatus; diff --git a/modules/commands/ns_suspend.cpp b/modules/commands/ns_suspend.cpp index 32de2048e..c5cc2f2e5 100644 --- a/modules/commands/ns_suspend.cpp +++ b/modules/commands/ns_suspend.cpp @@ -14,7 +14,9 @@ static ServiceReference<NickServService> nickserv("NickServService", "NickServ"); -struct NSSuspendInfo : SuspendInfo, Serializable +struct NSSuspendInfo + : SuspendInfo + , Serializable { NSSuspendInfo(Extensible *) : Serializable("NSSuspendInfo") { } @@ -52,7 +54,8 @@ struct NSSuspendInfo : SuspendInfo, Serializable } }; -class CommandNSSuspend : public Command +class CommandNSSuspend + : public Command { public: CommandNSSuspend(Module *creator) : Command(creator, "nickserv/suspend", 2, 3) @@ -150,7 +153,8 @@ public: } }; -class CommandNSUnSuspend : public Command +class CommandNSUnSuspend + : public Command { public: CommandNSUnSuspend(Module *creator) : Command(creator, "nickserv/unsuspend", 1, 1) @@ -199,7 +203,8 @@ public: } }; -class NSSuspend : public Module +class NSSuspend + : public Module { CommandNSSuspend commandnssuspend; CommandNSUnSuspend commandnsunsuspend; diff --git a/modules/commands/ns_update.cpp b/modules/commands/ns_update.cpp index 261f419b0..209d5991c 100644 --- a/modules/commands/ns_update.cpp +++ b/modules/commands/ns_update.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandNSUpdate : public Command +class CommandNSUpdate + : public Command { public: CommandNSUpdate(Module *creator) : Command(creator, "nickserv/update", 0, 0) @@ -47,7 +48,8 @@ public: } }; -class NSUpdate : public Module +class NSUpdate + : public Module { CommandNSUpdate commandnsupdate; diff --git a/modules/commands/os_akill.cpp b/modules/commands/os_akill.cpp index 57adea53e..b97bfbe5d 100644 --- a/modules/commands/os_akill.cpp +++ b/modules/commands/os_akill.cpp @@ -13,7 +13,8 @@ static ServiceReference<XLineManager> akills("XLineManager", "xlinemanager/sgline"); -class AkillDelCallback : public NumberList +class AkillDelCallback + : public NumberList { CommandSource &source; unsigned deleted = 0; @@ -55,7 +56,8 @@ public: } }; -class CommandOSAKill : public Command +class CommandOSAKill + : public Command { private: void DoAdd(CommandSource &source, const std::vector<Anope::string> ¶ms) @@ -262,7 +264,8 @@ private: if (!mask.empty() && isdigit(mask[0]) && mask.find_first_not_of("1234567890,-") == Anope::string::npos) { - class ListCallback : public NumberList + class ListCallback + : public NumberList { CommandSource &source; ListFormatter &list; @@ -468,7 +471,8 @@ public: } }; -class OSAKill : public Module +class OSAKill + : public Module { CommandOSAKill commandosakill; diff --git a/modules/commands/os_chankill.cpp b/modules/commands/os_chankill.cpp index e27929143..54966e23b 100644 --- a/modules/commands/os_chankill.cpp +++ b/modules/commands/os_chankill.cpp @@ -13,7 +13,8 @@ static ServiceReference<XLineManager> akills("XLineManager", "xlinemanager/sgline"); -class CommandOSChanKill : public Command +class CommandOSChanKill + : public Command { public: CommandOSChanKill(Module *creator) : Command(creator, "operserv/chankill", 2, 3) @@ -102,7 +103,8 @@ public: } }; -class OSChanKill : public Module +class OSChanKill + : public Module { CommandOSChanKill commandoschankill; diff --git a/modules/commands/os_config.cpp b/modules/commands/os_config.cpp index cb9ef3e9d..9895fc744 100644 --- a/modules/commands/os_config.cpp +++ b/modules/commands/os_config.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSConfig : public Command +class CommandOSConfig + : public Command { public: CommandOSConfig(Module *creator) : Command(creator, "operserv/config", 1, 4) @@ -132,7 +133,8 @@ public: } }; -class OSConfig : public Module +class OSConfig + : public Module { CommandOSConfig commandosconfig; diff --git a/modules/commands/os_defcon.cpp b/modules/commands/os_defcon.cpp index a41b104c9..5ef148faa 100644 --- a/modules/commands/os_defcon.cpp +++ b/modules/commands/os_defcon.cpp @@ -105,7 +105,8 @@ static ServiceReference<GlobalService> GlobalService("GlobalService", "Global"); static Timer *timeout; -class DefConTimeout : public Timer +class DefConTimeout + : public Timer { int level; @@ -144,7 +145,8 @@ public: } }; -class CommandOSDefcon : public Command +class CommandOSDefcon + : public Command { void SendLevels(CommandSource &source) { @@ -244,7 +246,8 @@ public: } }; -class OSDefcon : public Module +class OSDefcon + : public Module { ServiceReference<SessionService> session_service; ServiceReference<XLineManager> akills; diff --git a/modules/commands/os_dns.cpp b/modules/commands/os_dns.cpp index e82531ef6..003d22305 100644 --- a/modules/commands/os_dns.cpp +++ b/modules/commands/os_dns.cpp @@ -19,7 +19,8 @@ static Serialize::Checker<std::vector<DNSServer *> > dns_servers("DNSServer"); static std::map<Anope::string, std::list<time_t> > server_quit_times; -struct DNSZone : Serializable +struct DNSZone + : Serializable { Anope::string name; std::set<Anope::string, ci::less> servers; @@ -86,7 +87,8 @@ struct DNSZone : Serializable } }; -class DNSServer : public Serializable +class DNSServer + : public Serializable { Anope::string server_name; std::vector<Anope::string> ips; @@ -204,7 +206,8 @@ public: } }; -class CommandOSDNS : public Command +class CommandOSDNS + : public Command { void DisplayPoolState(CommandSource &source) { @@ -716,7 +719,8 @@ public: } }; -class ModuleDNS : public Module +class ModuleDNS + : public Module { Serialize::Type zone_type, dns_type; CommandOSDNS commandosdns; diff --git a/modules/commands/os_forbid.cpp b/modules/commands/os_forbid.cpp index 5a4af66e7..fb18a8e5d 100644 --- a/modules/commands/os_forbid.cpp +++ b/modules/commands/os_forbid.cpp @@ -14,7 +14,9 @@ static ServiceReference<NickServService> nickserv("NickServService", "NickServ"); -struct ForbidDataImpl : ForbidData, Serializable +struct ForbidDataImpl + : ForbidData + , Serializable { ForbidDataImpl() : Serializable("ForbidData") { } void Serialize(Serialize::Data &data) const override; @@ -59,7 +61,8 @@ Serializable* ForbidDataImpl::Unserialize(Serializable *obj, Serialize::Data &da return fb; } -class MyForbidService : public ForbidService +class MyForbidService + : public ForbidService { Serialize::Checker<std::vector<ForbidData *>[FT_SIZE - 1]> forbid_data; @@ -146,7 +149,8 @@ public: } }; -class CommandOSForbid : public Command +class CommandOSForbid + : public Command { ServiceReference<ForbidService> fs; public: @@ -430,7 +434,8 @@ public: } }; -class OSForbid : public Module +class OSForbid + : public Module { MyForbidService forbidService; Serialize::Type forbiddata_type; diff --git a/modules/commands/os_ignore.cpp b/modules/commands/os_ignore.cpp index 3fe820bce..006980299 100644 --- a/modules/commands/os_ignore.cpp +++ b/modules/commands/os_ignore.cpp @@ -12,7 +12,9 @@ #include "module.h" #include "modules/os_ignore.h" -struct IgnoreDataImpl : IgnoreData, Serializable +struct IgnoreDataImpl + : IgnoreData + , Serializable { IgnoreDataImpl() : Serializable("IgnoreData") { } ~IgnoreDataImpl() override; @@ -57,7 +59,8 @@ Serializable* IgnoreDataImpl::Unserialize(Serializable *obj, Serialize::Data &da } -class OSIgnoreService : public IgnoreService +class OSIgnoreService + : public IgnoreService { Serialize::Checker<std::vector<IgnoreData *> > ignores; @@ -154,7 +157,8 @@ public: } }; -class CommandOSIgnore : public Command +class CommandOSIgnore + : public Command { private: Anope::string RealMask(const Anope::string &mask) @@ -391,7 +395,8 @@ public: } }; -class OSIgnore : public Module +class OSIgnore + : public Module { Serialize::Type ignoredata_type; OSIgnoreService osignoreservice; diff --git a/modules/commands/os_info.cpp b/modules/commands/os_info.cpp index 2536e2251..c5036e04a 100644 --- a/modules/commands/os_info.cpp +++ b/modules/commands/os_info.cpp @@ -8,7 +8,8 @@ #include "module.h" -struct OperInfo : Serializable +struct OperInfo + : Serializable { Anope::string target; Anope::string info; @@ -32,7 +33,8 @@ struct OperInfo : Serializable static Serializable *Unserialize(Serializable *obj, Serialize::Data &data); }; -struct OperInfos : Serialize::Checker<std::vector<OperInfo *> > +struct OperInfos + : Serialize::Checker<std::vector<OperInfo *> > { OperInfos(Extensible *) : Serialize::Checker<std::vector<OperInfo *> >("OperInfo") { } @@ -93,7 +95,8 @@ Serializable *OperInfo::Unserialize(Serializable *obj, Serialize::Data &data) return o; } -class CommandOSInfo : public Command +class CommandOSInfo + : public Command { public: CommandOSInfo(Module *creator) : Command(creator, "operserv/info", 2, 3) @@ -245,7 +248,8 @@ public: } }; -class OSInfo : public Module +class OSInfo + : public Module { CommandOSInfo commandosinfo; ExtensibleItem<OperInfos> oinfo; diff --git a/modules/commands/os_jupe.cpp b/modules/commands/os_jupe.cpp index 7e2189708..2bec69d05 100644 --- a/modules/commands/os_jupe.cpp +++ b/modules/commands/os_jupe.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSJupe : public Command +class CommandOSJupe + : public Command { public: CommandOSJupe(Module *creator) : Command(creator, "operserv/jupe", 1, 2) @@ -65,7 +66,8 @@ public: } }; -class OSJupe : public Module +class OSJupe + : public Module { CommandOSJupe commandosjupe; diff --git a/modules/commands/os_kick.cpp b/modules/commands/os_kick.cpp index 03f47fda9..14261e048 100644 --- a/modules/commands/os_kick.cpp +++ b/modules/commands/os_kick.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSKick : public Command +class CommandOSKick + : public Command { public: CommandOSKick(Module *creator) : Command(creator, "operserv/kick", 3, 3) @@ -69,7 +70,8 @@ public: } }; -class OSKick : public Module +class OSKick + : public Module { CommandOSKick commandoskick; diff --git a/modules/commands/os_kill.cpp b/modules/commands/os_kill.cpp index 95f1f2548..40c640826 100644 --- a/modules/commands/os_kill.cpp +++ b/modules/commands/os_kill.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSKill : public Command +class CommandOSKill + : public Command { public: CommandOSKill(Module *creator) : Command(creator, "operserv/kill", 1, 2) @@ -52,7 +53,8 @@ public: } }; -class OSKill : public Module +class OSKill + : public Module { CommandOSKill commandoskill; diff --git a/modules/commands/os_list.cpp b/modules/commands/os_list.cpp index e1618c7e3..514b9f523 100644 --- a/modules/commands/os_list.cpp +++ b/modules/commands/os_list.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSChanList : public Command +class CommandOSChanList + : public Command { public: CommandOSChanList(Module *creator) : Command(creator, "operserv/chanlist", 0, 2) @@ -128,7 +129,8 @@ public: } }; -class CommandOSUserList : public Command +class CommandOSUserList + : public Command { public: CommandOSUserList(Module *creator) : Command(creator, "operserv/userlist", 0, 2) @@ -270,7 +272,8 @@ public: } }; -class OSList : public Module +class OSList + : public Module { CommandOSChanList commandoschanlist; CommandOSUserList commandosuserlist; diff --git a/modules/commands/os_login.cpp b/modules/commands/os_login.cpp index bea9a210d..7cd24dc90 100644 --- a/modules/commands/os_login.cpp +++ b/modules/commands/os_login.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSLogin : public Command +class CommandOSLogin + : public Command { public: CommandOSLogin(Module *creator) : Command(creator, "operserv/login", 1, 1) @@ -61,7 +62,8 @@ public: } }; -class CommandOSLogout : public Command +class CommandOSLogout + : public Command { public: CommandOSLogout(Module *creator) : Command(creator, "operserv/logout", 0, 0) @@ -103,7 +105,8 @@ public: } }; -class OSLogin : public Module +class OSLogin + : public Module { CommandOSLogin commandoslogin; CommandOSLogout commandoslogout; diff --git a/modules/commands/os_logsearch.cpp b/modules/commands/os_logsearch.cpp index cec0d0b50..79fc597b5 100644 --- a/modules/commands/os_logsearch.cpp +++ b/modules/commands/os_logsearch.cpp @@ -13,7 +13,8 @@ static unsigned int HARDMAX = 65536; -class CommandOSLogSearch : public Command +class CommandOSLogSearch + : public Command { static inline Anope::string CreateLogName(const Anope::string &file, time_t t = Anope::CurTime) { @@ -171,7 +172,8 @@ public: } }; -class OSLogSearch : public Module +class OSLogSearch + : public Module { CommandOSLogSearch commandoslogsearch; diff --git a/modules/commands/os_mode.cpp b/modules/commands/os_mode.cpp index b432d4c15..7140f5246 100644 --- a/modules/commands/os_mode.cpp +++ b/modules/commands/os_mode.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSMode : public Command +class CommandOSMode + : public Command { public: CommandOSMode(Module *creator) : Command(creator, "operserv/mode", 2, 3) @@ -135,7 +136,8 @@ public: } }; -class CommandOSUMode : public Command +class CommandOSUMode + : public Command { public: CommandOSUMode(Module *creator) : Command(creator, "operserv/umode", 2, 2) @@ -173,7 +175,8 @@ public: } }; -class OSMode : public Module +class OSMode + : public Module { CommandOSMode commandosmode; CommandOSUMode commandosumode; diff --git a/modules/commands/os_modinfo.cpp b/modules/commands/os_modinfo.cpp index ec19bee87..802154945 100644 --- a/modules/commands/os_modinfo.cpp +++ b/modules/commands/os_modinfo.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSModInfo : public Command +class CommandOSModInfo + : public Command { public: CommandOSModInfo(Module *creator) : Command(creator, "operserv/modinfo", 1, 1) @@ -68,7 +69,8 @@ public: } }; -class CommandOSModList : public Command +class CommandOSModList + : public Command { public: CommandOSModList(Module *creator) : Command(creator, "operserv/modlist", 0, 1) @@ -192,7 +194,8 @@ public: } }; -class OSModInfo : public Module +class OSModInfo + : public Module { CommandOSModInfo commandosmodinfo; CommandOSModList commandosmodlist; diff --git a/modules/commands/os_module.cpp b/modules/commands/os_module.cpp index 7db33a132..f8839af74 100644 --- a/modules/commands/os_module.cpp +++ b/modules/commands/os_module.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSModLoad : public Command +class CommandOSModLoad + : public Command { public: CommandOSModLoad(Module *creator) : Command(creator, "operserv/modload", 1, 1) @@ -48,7 +49,8 @@ public: } }; -class CommandOSModReLoad : public Command +class CommandOSModReLoad + : public Command { public: CommandOSModReLoad(Module *creator) : Command(creator, "operserv/modreload", 1, 1) @@ -120,7 +122,8 @@ public: } }; -class CommandOSModUnLoad : public Command +class CommandOSModUnLoad + : public Command { public: CommandOSModUnLoad(Module *creator) : Command(creator, "operserv/modunload", 1, 1) @@ -170,7 +173,8 @@ public: } }; -class OSModule : public Module +class OSModule + : public Module { CommandOSModLoad commandosmodload; CommandOSModReLoad commandosmodreload; diff --git a/modules/commands/os_news.cpp b/modules/commands/os_news.cpp index 631c7abb5..e0c48de59 100644 --- a/modules/commands/os_news.cpp +++ b/modules/commands/os_news.cpp @@ -64,7 +64,8 @@ struct NewsMessages msgarray[] = { } }; -struct MyNewsItem : NewsItem +struct MyNewsItem + : NewsItem { void Serialize(Serialize::Data &data) const override { @@ -98,7 +99,8 @@ struct MyNewsItem : NewsItem } }; -class MyNewsService : public NewsService +class MyNewsService + : public NewsService { std::vector<NewsItem *> newsItems[3]; public: @@ -147,7 +149,8 @@ static const char **findmsgs(NewsType type) return NULL; } -class NewsBase : public Command +class NewsBase + : public Command { ServiceReference<NewsService> ns; @@ -296,7 +299,8 @@ public: bool OnHelp(CommandSource &source, const Anope::string &subcommand) override = 0; }; -class CommandOSLogonNews : public NewsBase +class CommandOSLogonNews + : public NewsBase { public: CommandOSLogonNews(Module *creator) : NewsBase(creator, "operserv/logonnews") @@ -323,7 +327,8 @@ public: } }; -class CommandOSOperNews : public NewsBase +class CommandOSOperNews + : public NewsBase { public: CommandOSOperNews(Module *creator) : NewsBase(creator, "operserv/opernews") @@ -350,7 +355,8 @@ public: } }; -class CommandOSRandomNews : public NewsBase +class CommandOSRandomNews + : public NewsBase { public: CommandOSRandomNews(Module *creator) : NewsBase(creator, "operserv/randomnews") @@ -376,7 +382,8 @@ public: static unsigned cur_rand_news = 0; -class OSNews : public Module +class OSNews + : public Module { MyNewsService newsservice; Serialize::Type newsitem_type; diff --git a/modules/commands/os_noop.cpp b/modules/commands/os_noop.cpp index ce1f6bd98..0d11e0606 100644 --- a/modules/commands/os_noop.cpp +++ b/modules/commands/os_noop.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSNOOP : public Command +class CommandOSNOOP + : public Command { public: CommandOSNOOP(Module *creator) : Command(creator, "operserv/noop", 2, 2) @@ -71,7 +72,8 @@ public: } }; -class OSNOOP : public Module +class OSNOOP + : public Module { CommandOSNOOP commandosnoop; PrimitiveExtensibleItem<Anope::string> noop; diff --git a/modules/commands/os_oper.cpp b/modules/commands/os_oper.cpp index 4c9fb6e24..c493b8c82 100644 --- a/modules/commands/os_oper.cpp +++ b/modules/commands/os_oper.cpp @@ -11,7 +11,9 @@ #include "module.h" -struct MyOper : Oper, Serializable +struct MyOper + : Oper + , Serializable { MyOper(const Anope::string &n, OperType *o) : Oper(n, o), Serializable("Oper") { } @@ -46,7 +48,8 @@ struct MyOper : Oper, Serializable } }; -class CommandOSOper : public Command +class CommandOSOper + : public Command { bool HasPrivs(CommandSource &source, OperType *ot) const { @@ -252,7 +255,8 @@ public: } }; -class OSOper : public Module +class OSOper + : public Module { Serialize::Type myoper_type; CommandOSOper commandosoper; diff --git a/modules/commands/os_reload.cpp b/modules/commands/os_reload.cpp index d364aeb88..1a87babf1 100644 --- a/modules/commands/os_reload.cpp +++ b/modules/commands/os_reload.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSReload : public Command +class CommandOSReload + : public Command { public: CommandOSReload(Module *creator) : Command(creator, "operserv/reload", 0, 0) @@ -52,7 +53,8 @@ public: } }; -class OSReload : public Module +class OSReload + : public Module { CommandOSReload commandosreload; diff --git a/modules/commands/os_session.cpp b/modules/commands/os_session.cpp index c04f507e4..8b746bb6d 100644 --- a/modules/commands/os_session.cpp +++ b/modules/commands/os_session.cpp @@ -35,7 +35,8 @@ namespace unsigned ipv6_cidr; } -class MySessionService : public SessionService +class MySessionService + : public SessionService { SessionMap Sessions; Serialize::Checker<ExceptionVector> Exceptions; @@ -126,7 +127,8 @@ public: } }; -class ExceptionDelCallback : public NumberList +class ExceptionDelCallback + : public NumberList { protected: CommandSource &source; @@ -168,7 +170,8 @@ public: } }; -class CommandOSSession : public Command +class CommandOSSession + : public Command { private: void DoList(CommandSource &source, const std::vector<Anope::string> ¶ms) @@ -281,7 +284,8 @@ public: } }; -class CommandOSException : public Command +class CommandOSException + : public Command { private: void DoAdd(CommandSource &source, const std::vector<Anope::string> ¶ms) @@ -431,7 +435,8 @@ private: if (!mask.empty() && mask.find_first_not_of("1234567890,-") == Anope::string::npos) { - class ExceptionListCallback : public NumberList + class ExceptionListCallback + : public NumberList { CommandSource &source; ListFormatter &list; @@ -577,7 +582,8 @@ public: } }; -class OSSession : public Module +class OSSession + : public Module { Serialize::Type exception_type; MySessionService ss; diff --git a/modules/commands/os_set.cpp b/modules/commands/os_set.cpp index d702b8052..df5301c71 100644 --- a/modules/commands/os_set.cpp +++ b/modules/commands/os_set.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSSet : public Command +class CommandOSSet + : public Command { private: void DoList(CommandSource &source) @@ -253,7 +254,8 @@ public: } }; -class OSSet : public Module +class OSSet + : public Module { CommandOSSet commandosset; diff --git a/modules/commands/os_shutdown.cpp b/modules/commands/os_shutdown.cpp index 0c0acb0f8..4db78d11d 100644 --- a/modules/commands/os_shutdown.cpp +++ b/modules/commands/os_shutdown.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSQuit : public Command +class CommandOSQuit + : public Command { public: CommandOSQuit(Module *creator) : Command(creator, "operserv/quit", 0, 0) @@ -39,7 +40,8 @@ public: } }; -class CommandOSRestart : public Command +class CommandOSRestart + : public Command { public: CommandOSRestart(Module *creator) : Command(creator, "operserv/restart", 0, 0) @@ -65,7 +67,8 @@ public: } }; -class CommandOSShutdown : public Command +class CommandOSShutdown + : public Command { public: CommandOSShutdown(Module *creator) : Command(creator, "operserv/shutdown", 0, 0) @@ -91,7 +94,8 @@ public: } }; -class OSShutdown : public Module +class OSShutdown + : public Module { CommandOSQuit commandosquit; CommandOSRestart commandosrestart; diff --git a/modules/commands/os_stats.cpp b/modules/commands/os_stats.cpp index e7575f288..de00b22f8 100644 --- a/modules/commands/os_stats.cpp +++ b/modules/commands/os_stats.cpp @@ -12,7 +12,8 @@ #include "module.h" #include "modules/os_session.h" -struct Stats : Serializable +struct Stats + : Serializable { static Stats *me; @@ -58,7 +59,8 @@ static int stats_count_servers(Server *s) return count; } -class CommandOSStats : public Command +class CommandOSStats + : public Command { ServiceReference<XLineManager> akills, snlines, sqlines; private: @@ -255,7 +257,8 @@ public: } }; -class OSStats : public Module +class OSStats + : public Module { CommandOSStats commandosstats; Serialize::Type stats_type; diff --git a/modules/commands/os_svs.cpp b/modules/commands/os_svs.cpp index e9ef64bf9..4125453e2 100644 --- a/modules/commands/os_svs.cpp +++ b/modules/commands/os_svs.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSSVSNick : public Command +class CommandOSSVSNick + : public Command { public: CommandOSSVSNick(Module *creator) : Command(creator, "operserv/svsnick", 2, 2) @@ -70,7 +71,8 @@ public: } }; -class CommandOSSVSJoin : public Command +class CommandOSSVSJoin + : public Command { public: CommandOSSVSJoin(Module *creator) : Command(creator, "operserv/svsjoin", 2, 2) @@ -114,7 +116,8 @@ public: } }; -class CommandOSSVSPart : public Command +class CommandOSSVSPart + : public Command { public: CommandOSSVSPart(Module *creator) : Command(creator, "operserv/svspart", 2, 3) @@ -162,7 +165,8 @@ public: } }; -class OSSVS : public Module +class OSSVS + : public Module { CommandOSSVSNick commandossvsnick; CommandOSSVSJoin commandossvsjoin; diff --git a/modules/commands/os_sxline.cpp b/modules/commands/os_sxline.cpp index 07ba3cca3..015d52660 100644 --- a/modules/commands/os_sxline.cpp +++ b/modules/commands/os_sxline.cpp @@ -11,7 +11,8 @@ #include "module.h" -class SXLineDelCallback : public NumberList +class SXLineDelCallback + : public NumberList { XLineManager *xlm; Command *command; @@ -54,7 +55,8 @@ public: } }; -class CommandOSSXLineBase : public Command +class CommandOSSXLineBase + : public Command { private: virtual XLineManager* xlm() = 0; @@ -118,7 +120,8 @@ private: if (!mask.empty() && isdigit(mask[0]) && mask.find_first_not_of("1234567890,-") == Anope::string::npos) { - class SXLineListCallback : public NumberList + class SXLineListCallback + : public NumberList { XLineManager *xlm; CommandSource &source; @@ -256,7 +259,8 @@ public: bool OnHelp(CommandSource &source, const Anope::string &subcommand) override = 0; }; -class CommandOSSNLine : public CommandOSSXLineBase +class CommandOSSNLine + : public CommandOSSXLineBase { XLineManager *xlm() override { @@ -480,7 +484,8 @@ public: } }; -class CommandOSSQLine : public CommandOSSXLineBase +class CommandOSSQLine + : public CommandOSSXLineBase { XLineManager *xlm() override { @@ -710,7 +715,8 @@ public: } }; -class OSSXLine : public Module +class OSSXLine + : public Module { CommandOSSNLine commandossnline; CommandOSSQLine commandossqline; diff --git a/modules/commands/os_update.cpp b/modules/commands/os_update.cpp index 1a855c1a8..aafde628f 100644 --- a/modules/commands/os_update.cpp +++ b/modules/commands/os_update.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandOSUpdate : public Command +class CommandOSUpdate + : public Command { public: CommandOSUpdate(Module *creator) : Command(creator, "operserv/update", 0, 0) @@ -37,7 +38,8 @@ public: } }; -class OSUpdate : public Module +class OSUpdate + : public Module { CommandOSUpdate commandosupdate; diff --git a/modules/cs_statusupdate.cpp b/modules/cs_statusupdate.cpp index 417489256..789343396 100644 --- a/modules/cs_statusupdate.cpp +++ b/modules/cs_statusupdate.cpp @@ -8,7 +8,8 @@ #include "module.h" -class StatusUpdate : public Module +class StatusUpdate + : public Module { public: StatusUpdate(const Anope::string &modname, const Anope::string &creator) : Module(modname, creator, VENDOR) diff --git a/modules/database/db_flatfile.cpp b/modules/database/db_flatfile.cpp index 6e53d0274..b0f766e95 100644 --- a/modules/database/db_flatfile.cpp +++ b/modules/database/db_flatfile.cpp @@ -15,7 +15,8 @@ #include <sys/wait.h> #endif -class SaveData : public Serialize::Data +class SaveData + : public Serialize::Data { public: Anope::string last; @@ -33,7 +34,8 @@ public: } }; -class LoadData : public Serialize::Data +class LoadData + : public Serialize::Data { public: std::fstream *fs = nullptr; @@ -99,7 +101,9 @@ public: } }; -class DBFlatFile : public Module, public Pipe +class DBFlatFile + : public Module + , public Pipe { /* Day the last backup was on */ int last_day = 0; diff --git a/modules/database/db_old.cpp b/modules/database/db_old.cpp index fb8d57fbb..eca898b59 100644 --- a/modules/database/db_old.cpp +++ b/modules/database/db_old.cpp @@ -1297,7 +1297,8 @@ static void LoadNews() close_db(f); } -class DBOld : public Module +class DBOld + : public Module { PrimitiveExtensibleItem<uint32_t> mlock_on, mlock_off, mlock_limit; PrimitiveExtensibleItem<Anope::string> mlock_key; diff --git a/modules/database/db_redis.cpp b/modules/database/db_redis.cpp index 54080c60b..392108849 100644 --- a/modules/database/db_redis.cpp +++ b/modules/database/db_redis.cpp @@ -14,7 +14,8 @@ using namespace Redis; class DatabaseRedis; static DatabaseRedis *me; -class Data : public Serialize::Data +class Data + : public Serialize::Data { public: std::map<Anope::string, std::stringstream *> data; @@ -51,7 +52,8 @@ public: } }; -class TypeLoader : public Interface +class TypeLoader + : public Interface { Anope::string type; public: @@ -60,7 +62,8 @@ public: void OnResult(const Reply &r) override; }; -class ObjectLoader : public Interface +class ObjectLoader + : public Interface { Anope::string type; int64_t id; @@ -71,7 +74,8 @@ public: void OnResult(const Reply &r) override; }; -class IDInterface : public Interface +class IDInterface + : public Interface { Reference<Serializable> o; public: @@ -80,7 +84,8 @@ public: void OnResult(const Reply &r) override; }; -class Deleter : public Interface +class Deleter + : public Interface { Anope::string type; int64_t id; @@ -90,7 +95,8 @@ public: void OnResult(const Reply &r) override; }; -class Updater : public Interface +class Updater + : public Interface { Anope::string type; int64_t id; @@ -100,7 +106,8 @@ public: void OnResult(const Reply &r) override; }; -class ModifiedObject : public Interface +class ModifiedObject + : public Interface { Anope::string type; int64_t id; @@ -110,7 +117,8 @@ public: void OnResult(const Reply &r) override; }; -class SubscriptionListener : public Interface +class SubscriptionListener + : public Interface { public: SubscriptionListener(Module *creator) : Interface(creator) { } @@ -118,7 +126,9 @@ public: void OnResult(const Reply &r) override; }; -class DatabaseRedis : public Module, public Pipe +class DatabaseRedis + : public Module + , public Pipe { SubscriptionListener sl; std::set<Serializable *> updated_items; diff --git a/modules/database/db_sql.cpp b/modules/database/db_sql.cpp index 0ebbb26bd..c352a3be2 100644 --- a/modules/database/db_sql.cpp +++ b/modules/database/db_sql.cpp @@ -14,7 +14,8 @@ using namespace SQL; -class SQLSQLInterface : public Interface +class SQLSQLInterface + : public Interface { public: SQLSQLInterface(Module *o) : Interface(o) { } @@ -33,7 +34,8 @@ public: } }; -class ResultSQLSQLInterface : public SQLSQLInterface +class ResultSQLSQLInterface + : public SQLSQLInterface { Reference<Serializable> obj; @@ -55,7 +57,9 @@ public: } }; -class DBSQL : public Module, public Pipe +class DBSQL + : public Module + , public Pipe { ServiceReference<Provider> sql; SQLSQLInterface sqlinterface; diff --git a/modules/database/db_sql_live.cpp b/modules/database/db_sql_live.cpp index cc7068c58..0e47eab27 100644 --- a/modules/database/db_sql_live.cpp +++ b/modules/database/db_sql_live.cpp @@ -11,7 +11,9 @@ using namespace SQL; -class DBMySQL : public Module, public Pipe +class DBMySQL + : public Module + , public Pipe { private: Anope::string prefix; diff --git a/modules/encryption/enc_bcrypt.cpp b/modules/encryption/enc_bcrypt.cpp index 996cdb268..635ac18be 100644 --- a/modules/encryption/enc_bcrypt.cpp +++ b/modules/encryption/enc_bcrypt.cpp @@ -13,7 +13,8 @@ #include "bcrypt/crypt_blowfish.c" -class EBCRYPT : public Module +class EBCRYPT + : public Module { unsigned int rounds; diff --git a/modules/encryption/enc_md5.cpp b/modules/encryption/enc_md5.cpp index 83b74ea09..68a72ba04 100644 --- a/modules/encryption/enc_md5.cpp +++ b/modules/encryption/enc_md5.cpp @@ -86,7 +86,8 @@ static const uint32_t md5_iv[4] = 0x67452301, 0xefcdab89, 0x98badcfe, 0x10325476 }; -class MD5Context : public Encryption::Context +class MD5Context + : public Encryption::Context { unsigned state[4]; /* state (ABCD) */ unsigned count[2]; /* number of bits, modulo 2^64 (lsb first) */ @@ -318,7 +319,8 @@ public: } }; -class MD5Provider : public Encryption::Provider +class MD5Provider + : public Encryption::Provider { public: MD5Provider(Module *creator) : Encryption::Provider(creator, "md5") { } @@ -337,7 +339,8 @@ public: } }; -class EMD5 : public Module +class EMD5 + : public Module { MD5Provider md5provider; diff --git a/modules/encryption/enc_none.cpp b/modules/encryption/enc_none.cpp index 0441cdf76..d243cc132 100644 --- a/modules/encryption/enc_none.cpp +++ b/modules/encryption/enc_none.cpp @@ -9,7 +9,8 @@ #include "module.h" -class ENone : public Module +class ENone + : public Module { public: ENone(const Anope::string &modname, const Anope::string &creator) : Module(modname, creator, ENCRYPTION | VENDOR) diff --git a/modules/encryption/enc_old.cpp b/modules/encryption/enc_old.cpp index 70871ff0a..cfab00987 100644 --- a/modules/encryption/enc_old.cpp +++ b/modules/encryption/enc_old.cpp @@ -14,7 +14,8 @@ static ServiceReference<Encryption::Provider> md5("Encryption::Provider", "md5"); -class OldMD5Provider : public Encryption::Provider +class OldMD5Provider + : public Encryption::Provider { public: OldMD5Provider(Module *creator) : Encryption::Provider(creator, "oldmd5") { } @@ -34,7 +35,8 @@ public: } }; -class EOld : public Module +class EOld + : public Module { OldMD5Provider oldmd5provider; diff --git a/modules/encryption/enc_sha1.cpp b/modules/encryption/enc_sha1.cpp index e5994e0ad..8b941ab63 100644 --- a/modules/encryption/enc_sha1.cpp +++ b/modules/encryption/enc_sha1.cpp @@ -54,7 +54,8 @@ static const uint32_t sha1_iv[5] = 0x67452301, 0xEFCDAB89, 0x98BADCFE, 0x10325476, 0xC3D2E1F0 }; -class SHA1Context : public Encryption::Context +class SHA1Context + : public Encryption::Context { uint32_t state[5]; uint32_t count[2]; @@ -178,7 +179,8 @@ public: } }; -class SHA1Provider : public Encryption::Provider +class SHA1Provider + : public Encryption::Provider { public: SHA1Provider(Module *creator) : Encryption::Provider(creator, "sha1") { } @@ -197,7 +199,8 @@ public: } }; -class ESHA1 : public Module +class ESHA1 + : public Module { SHA1Provider sha1provider; diff --git a/modules/encryption/enc_sha256.cpp b/modules/encryption/enc_sha256.cpp index 0928536de..9e9192e75 100644 --- a/modules/encryption/enc_sha256.cpp +++ b/modules/encryption/enc_sha256.cpp @@ -111,7 +111,8 @@ static const uint32_t sha256_k[64] = /** An sha256 context */ -class SHA256Context : public Encryption::Context +class SHA256Context + : public Encryption::Context { void Transform(unsigned char *message, unsigned block_nb) { @@ -216,7 +217,8 @@ public: } }; -class SHA256Provider : public Encryption::Provider +class SHA256Provider + : public Encryption::Provider { public: SHA256Provider(Module *creator) : Encryption::Provider(creator, "sha256") { } @@ -235,7 +237,8 @@ public: } }; -class ESHA256 : public Module +class ESHA256 + : public Module { SHA256Provider sha256provider; diff --git a/modules/extra/m_ldap.cpp b/modules/extra/m_ldap.cpp index 799e15c6a..bdfa243f0 100644 --- a/modules/extra/m_ldap.cpp +++ b/modules/extra/m_ldap.cpp @@ -72,7 +72,8 @@ public: virtual int run() = 0; }; -class LDAPBind : public LDAPRequest +class LDAPBind + : public LDAPRequest { Anope::string who, pass; @@ -88,7 +89,8 @@ public: int run() override; }; -class LDAPSearchRequest : public LDAPRequest +class LDAPSearchRequest + : public LDAPRequest { Anope::string base; Anope::string filter; @@ -105,7 +107,8 @@ public: int run() override; }; -class LDAPAdd : public LDAPRequest +class LDAPAdd + : public LDAPRequest { Anope::string dn; LDAPMods attributes; @@ -122,7 +125,8 @@ public: int run() override; }; -class LDAPDel : public LDAPRequest +class LDAPDel + : public LDAPRequest { Anope::string dn; @@ -137,7 +141,8 @@ public: int run() override; }; -class LDAPModify : public LDAPRequest +class LDAPModify + : public LDAPRequest { Anope::string base; LDAPMods attributes; @@ -154,7 +159,10 @@ public: int run() override; }; -class LDAPService : public LDAPProvider, public Thread, public Condition +class LDAPService + : public LDAPProvider + , public Thread + , public Condition { Anope::string server; Anope::string admin_binddn; @@ -501,7 +509,9 @@ public: } }; -class ModuleLDAP : public Module, public Pipe +class ModuleLDAP + : public Module + , public Pipe { std::map<Anope::string, LDAPService *> LDAPServices; diff --git a/modules/extra/m_ldap_authentication.cpp b/modules/extra/m_ldap_authentication.cpp index 0de029cdf..f3ccb9ba7 100644 --- a/modules/extra/m_ldap_authentication.cpp +++ b/modules/extra/m_ldap_authentication.cpp @@ -36,7 +36,8 @@ struct IdentifyInfo } }; -class IdentifyInterface : public LDAPInterface +class IdentifyInterface + : public LDAPInterface { IdentifyInfo *ii; @@ -127,7 +128,8 @@ public: } }; -class OnIdentifyInterface : public LDAPInterface +class OnIdentifyInterface + : public LDAPInterface { Anope::string uid; @@ -172,7 +174,8 @@ public: } }; -class OnRegisterInterface : public LDAPInterface +class OnRegisterInterface + : public LDAPInterface { public: OnRegisterInterface(Module *m) : LDAPInterface(m) { } @@ -188,7 +191,8 @@ public: } }; -class ModuleLDAPAuthentication : public Module +class ModuleLDAPAuthentication + : public Module { ServiceReference<LDAPProvider> ldap; OnRegisterInterface orinterface; diff --git a/modules/extra/m_ldap_oper.cpp b/modules/extra/m_ldap_oper.cpp index e077215a3..b949782e1 100644 --- a/modules/extra/m_ldap_oper.cpp +++ b/modules/extra/m_ldap_oper.cpp @@ -12,7 +12,8 @@ static std::set<Oper *> my_opers; static Anope::string opertype_attribute; -class IdentifyInterface : public LDAPInterface +class IdentifyInterface + : public LDAPInterface { Reference<User> u; @@ -75,7 +76,8 @@ public: } }; -class LDAPOper : public Module +class LDAPOper + : public Module { ServiceReference<LDAPProvider> ldap; diff --git a/modules/extra/m_mysql.cpp b/modules/extra/m_mysql.cpp index 7a7adc943..2ccc36d76 100644 --- a/modules/extra/m_mysql.cpp +++ b/modules/extra/m_mysql.cpp @@ -59,7 +59,8 @@ struct QueryResult /** A MySQL result */ -class MySQLResult : public Result +class MySQLResult + : public Result { MYSQL_RES *res = nullptr; @@ -107,7 +108,8 @@ public: /** A MySQL connection, there can be multiple */ -class MySQLService : public Provider +class MySQLService + : public Provider { std::map<Anope::string, std::set<Anope::string> > active_schema; @@ -156,7 +158,9 @@ public: /** The SQL thread used to execute queries */ -class DispatcherThread : public Thread, public Condition +class DispatcherThread + : public Thread + , public Condition { public: DispatcherThread() : Thread() { } @@ -166,7 +170,10 @@ public: class ModuleSQL; static ModuleSQL *me; -class ModuleSQL : public Module, public Pipe + +class ModuleSQL + : public Module + , public Pipe { /* SQL connections */ std::map<Anope::string, MySQLService *> MySQLServices; diff --git a/modules/extra/m_regex_pcre2.cpp b/modules/extra/m_regex_pcre2.cpp index f4fa89d90..f573adaf3 100644 --- a/modules/extra/m_regex_pcre2.cpp +++ b/modules/extra/m_regex_pcre2.cpp @@ -14,7 +14,8 @@ #define PCRE2_CODE_UNIT_WIDTH 8 #include <pcre2.h> -class PCRERegex : public Regex +class PCRERegex + : public Regex { pcre2_code *regex; @@ -47,7 +48,8 @@ public: } }; -class PCRERegexProvider : public RegexProvider +class PCRERegexProvider + : public RegexProvider { public: PCRERegexProvider(Module *creator) : RegexProvider(creator, "regex/pcre") { } @@ -58,7 +60,8 @@ public: } }; -class ModuleRegexPCRE : public Module +class ModuleRegexPCRE + : public Module { PCRERegexProvider pcre_regex_provider; diff --git a/modules/extra/m_regex_posix.cpp b/modules/extra/m_regex_posix.cpp index 9569a3b46..c4217a5c4 100644 --- a/modules/extra/m_regex_posix.cpp +++ b/modules/extra/m_regex_posix.cpp @@ -10,7 +10,8 @@ #include <sys/types.h> #include <regex.h> -class POSIXRegex : public Regex +class POSIXRegex + : public Regex { regex_t regbuf; @@ -38,7 +39,8 @@ public: } }; -class POSIXRegexProvider : public RegexProvider +class POSIXRegexProvider + : public RegexProvider { public: POSIXRegexProvider(Module *creator) : RegexProvider(creator, "regex/posix") { } @@ -49,7 +51,8 @@ public: } }; -class ModuleRegexPOSIX : public Module +class ModuleRegexPOSIX + : public Module { POSIXRegexProvider posix_regex_provider; diff --git a/modules/extra/m_regex_tre.cpp b/modules/extra/m_regex_tre.cpp index 5c1745e10..61a5a79ec 100644 --- a/modules/extra/m_regex_tre.cpp +++ b/modules/extra/m_regex_tre.cpp @@ -11,7 +11,8 @@ #include "module.h" #include <tre/regex.h> -class TRERegex : public Regex +class TRERegex + : public Regex { regex_t regbuf; @@ -39,7 +40,8 @@ public: } }; -class TRERegexProvider : public RegexProvider +class TRERegexProvider + : public RegexProvider { public: TRERegexProvider(Module *creator) : RegexProvider(creator, "regex/tre") { } @@ -50,7 +52,8 @@ public: } }; -class ModuleRegexTRE : public Module +class ModuleRegexTRE + : public Module { TRERegexProvider tre_regex_provider; diff --git a/modules/extra/m_sql_authentication.cpp b/modules/extra/m_sql_authentication.cpp index 5e0ca33c2..829cf37fb 100644 --- a/modules/extra/m_sql_authentication.cpp +++ b/modules/extra/m_sql_authentication.cpp @@ -11,7 +11,8 @@ static Module *me; -class SQLAuthenticationResult : public SQL::Interface +class SQLAuthenticationResult + : public SQL::Interface { Reference<User> user; IdentifyRequest *req; @@ -73,7 +74,8 @@ public: } }; -class ModuleSQLAuthentication : public Module +class ModuleSQLAuthentication + : public Module { Anope::string engine; Anope::string query; diff --git a/modules/extra/m_sql_log.cpp b/modules/extra/m_sql_log.cpp index 7dd294898..bd8f81320 100644 --- a/modules/extra/m_sql_log.cpp +++ b/modules/extra/m_sql_log.cpp @@ -9,7 +9,8 @@ #include "module.h" #include "modules/sql.h" -class SQLLog : public Module +class SQLLog + : public Module { std::set<Anope::string> inited; Anope::string table; diff --git a/modules/extra/m_sql_oper.cpp b/modules/extra/m_sql_oper.cpp index 13a3b8521..931d1eeed 100644 --- a/modules/extra/m_sql_oper.cpp +++ b/modules/extra/m_sql_oper.cpp @@ -9,12 +9,14 @@ #include "module.h" #include "modules/sql.h" -struct SQLOper : Oper +struct SQLOper + : Oper { SQLOper(const Anope::string &n, OperType *o) : Oper(n, o) { } }; -class SQLOperResult : public SQL::Interface +class SQLOperResult + : public SQL::Interface { Reference<User> user; @@ -123,7 +125,8 @@ public: } }; -class ModuleSQLOper : public Module +class ModuleSQLOper + : public Module { Anope::string engine; Anope::string query; diff --git a/modules/extra/m_sqlite.cpp b/modules/extra/m_sqlite.cpp index 7abfc2f52..9905d2073 100644 --- a/modules/extra/m_sqlite.cpp +++ b/modules/extra/m_sqlite.cpp @@ -19,7 +19,8 @@ using namespace SQL; /** A SQLite result */ -class SQLiteResult : public Result +class SQLiteResult + : public Result { public: SQLiteResult(unsigned int i, const Query &q, const Anope::string &fq) : Result(i, q, fq) @@ -38,7 +39,8 @@ public: /** A SQLite database, there can be multiple */ -class SQLiteService : public Provider +class SQLiteService + : public Provider { std::map<Anope::string, std::set<Anope::string> > active_schema; @@ -68,7 +70,8 @@ public: Anope::string FromUnixtime(time_t) override; }; -class ModuleSQLite : public Module +class ModuleSQLite + : public Module { /* SQL connections */ std::map<Anope::string, SQLiteService *> SQLiteServices; diff --git a/modules/extra/m_ssl_gnutls.cpp b/modules/extra/m_ssl_gnutls.cpp index 87b182285..6daad09db 100644 --- a/modules/extra/m_ssl_gnutls.cpp +++ b/modules/extra/m_ssl_gnutls.cpp @@ -22,7 +22,8 @@ static GnuTLSModule *me; namespace GnuTLS { class X509CertCredentials; } -class MySSLService : public SSLService +class MySSLService + : public SSLService { public: MySSLService(Module *o, const Anope::string &n); @@ -33,7 +34,8 @@ public: void Init(Socket *s) override; }; -class SSLSocketIO : public SocketIO +class SSLSocketIO + : public SocketIO { public: gnutls_session_t sess = nullptr; @@ -284,7 +286,8 @@ namespace GnuTLS }; } -class GnuTLSModule : public Module +class GnuTLSModule + : public Module { GnuTLS::Init libinit; diff --git a/modules/extra/m_ssl_openssl.cpp b/modules/extra/m_ssl_openssl.cpp index 12cff478b..470f5f43f 100644 --- a/modules/extra/m_ssl_openssl.cpp +++ b/modules/extra/m_ssl_openssl.cpp @@ -23,7 +23,8 @@ static SSL_CTX *server_ctx, *client_ctx; -class MySSLService : public SSLService +class MySSLService + : public SSLService { public: MySSLService(Module *o, const Anope::string &n); @@ -34,7 +35,8 @@ public: void Init(Socket *s) override; }; -class SSLSocketIO : public SocketIO +class SSLSocketIO + : public SocketIO { public: /* The SSL socket for this socket */ @@ -91,7 +93,8 @@ public: class SSLModule; static SSLModule *me; -class SSLModule : public Module +class SSLModule + : public Module { Anope::string certfile, keyfile; diff --git a/modules/fantasy.cpp b/modules/fantasy.cpp index a0b994e69..740e9bad0 100644 --- a/modules/fantasy.cpp +++ b/modules/fantasy.cpp @@ -11,7 +11,8 @@ #include "module.h" -class CommandBSSetFantasy : public Command +class CommandBSSetFantasy + : public Command { public: CommandBSSetFantasy(Module *creator, const Anope::string &sname = "botserv/set/fantasy") : Command(creator, sname, 2, 2) @@ -80,7 +81,8 @@ public: } }; -class Fantasy : public Module +class Fantasy + : public Module { SerializableExtensibleItem<bool> fantasy; diff --git a/modules/m_dns.cpp b/modules/m_dns.cpp index 47f6a5a3f..57783cbe0 100644 --- a/modules/m_dns.cpp +++ b/modules/m_dns.cpp @@ -23,7 +23,8 @@ namespace /** A full packet sent or received to/from the nameserver */ -class Packet : public Query +class Packet + : public Query { static bool IsValidName(const Anope::string &name) { @@ -448,7 +449,8 @@ public: namespace DNS { - class ReplySocket : public virtual Socket + class ReplySocket + : public virtual Socket { public: ~ReplySocket() override = default; @@ -457,13 +459,17 @@ namespace DNS } /* Listens for TCP requests */ -class TCPSocket : public ListenSocket +class TCPSocket + : public ListenSocket { Manager *manager; public: /* A TCP client */ - class Client : public ClientSocket, public Timer, public ReplySocket + class Client + : public ClientSocket + , public Timer + , public ReplySocket { Manager *manager; Packet *packet = nullptr; @@ -550,7 +556,8 @@ public: }; /* Listens for UDP requests */ -class UDPSocket : public ReplySocket +class UDPSocket + : public ReplySocket { Manager *manager; std::deque<Packet *> packets; @@ -610,7 +617,8 @@ public: } }; -class NotifySocket : public Socket +class NotifySocket + : public Socket { Packet *packet; public: @@ -643,7 +651,9 @@ public: } }; -class MyManager : public Manager, public Timer +class MyManager + : public Manager + , public Timer { uint32_t serial; @@ -997,7 +1007,8 @@ private: }; -class ModuleDNS : public Module +class ModuleDNS + : public Module { MyManager manager; diff --git a/modules/m_dnsbl.cpp b/modules/m_dnsbl.cpp index bf36c34c2..d89f56fdd 100644 --- a/modules/m_dnsbl.cpp +++ b/modules/m_dnsbl.cpp @@ -39,7 +39,8 @@ struct Blacklist } }; -class DNSBLResolver : public Request +class DNSBLResolver + : public Request { Reference<User> user; Blacklist blacklist; @@ -94,7 +95,8 @@ public: } }; -class ModuleDNSBL : public Module +class ModuleDNSBL + : public Module { std::vector<Blacklist> blacklists; std::set<cidr> exempts; diff --git a/modules/m_helpchan.cpp b/modules/m_helpchan.cpp index 3ad56f132..661f71653 100644 --- a/modules/m_helpchan.cpp +++ b/modules/m_helpchan.cpp @@ -8,7 +8,8 @@ #include "module.h" -class HelpChannel : public Module +class HelpChannel + : public Module { public: HelpChannel(const Anope::string &modname, const Anope::string &creator) : Module(modname, creator, VENDOR) diff --git a/modules/m_httpd.cpp b/modules/m_httpd.cpp index fa9f03823..162ec3ada 100644 --- a/modules/m_httpd.cpp +++ b/modules/m_httpd.cpp @@ -37,7 +37,8 @@ static Anope::string GetStatusFromCode(HTTPError err) return "501 Not Implemented"; } -class MyHTTPClient : public HTTPClient +class MyHTTPClient + : public HTTPClient { HTTPProvider *provider; HTTPMessage message; @@ -282,7 +283,9 @@ public: } }; -class MyHTTPProvider : public HTTPProvider, public Timer +class MyHTTPProvider + : public HTTPProvider + , public Timer { int timeout; std::map<Anope::string, HTTPPage *> pages; @@ -329,7 +332,8 @@ public: } }; -class HTTPD : public Module +class HTTPD + : public Module { ServiceReference<SSLService> sslref; std::map<Anope::string, MyHTTPProvider *> providers; diff --git a/modules/m_proxyscan.cpp b/modules/m_proxyscan.cpp index e99b40751..ce8531e82 100644 --- a/modules/m_proxyscan.cpp +++ b/modules/m_proxyscan.cpp @@ -21,9 +21,12 @@ static Anope::string target_ip; static unsigned short target_port; static bool add_to_akill; -class ProxyCallbackListener : public ListenSocket +class ProxyCallbackListener + : public ListenSocket { - class ProxyCallbackClient : public ClientSocket, public BufferedSocket + class ProxyCallbackClient + : public ClientSocket + , public BufferedSocket { public: ProxyCallbackClient(ListenSocket *l, int f, const sockaddrs &a) : Socket(f, l->GetFamily()), ClientSocket(l, a), BufferedSocket() @@ -52,7 +55,8 @@ public: } }; -class ProxyConnect : public ConnectionSocket +class ProxyConnect + : public ConnectionSocket { static ServiceReference<XLineManager> akills; @@ -107,7 +111,9 @@ protected: ServiceReference<XLineManager> ProxyConnect::akills("XLineManager", "xlinemanager/sgline"); std::set<ProxyConnect *> ProxyConnect::proxies; -class HTTPProxyConnect : public ProxyConnect, public BufferedSocket +class HTTPProxyConnect + : public ProxyConnect + , public BufferedSocket { public: HTTPProxyConnect(ProxyCheck &p, unsigned short po) : Socket(-1), ProxyConnect(p, po), BufferedSocket() @@ -139,7 +145,9 @@ public: } }; -class SOCKS5ProxyConnect : public ProxyConnect, public BinarySocket +class SOCKS5ProxyConnect + : public ProxyConnect + , public BinarySocket { public: SOCKS5ProxyConnect(ProxyCheck &p, unsigned short po) : Socket(-1), ProxyConnect(p, po), BinarySocket() @@ -189,7 +197,8 @@ public: } }; -class ModuleProxyScan : public Module +class ModuleProxyScan + : public Module { Anope::string listen_ip; unsigned short listen_port; @@ -198,7 +207,8 @@ class ModuleProxyScan : public Module ProxyCallbackListener *listener; - class ConnectionTimeout : public Timer + class ConnectionTimeout + : public Timer { public: ConnectionTimeout(Module *c, long timeout) : Timer(c, timeout, Anope::CurTime, true) diff --git a/modules/m_redis.cpp b/modules/m_redis.cpp index 7e8f1dad3..b5a82985a 100644 --- a/modules/m_redis.cpp +++ b/modules/m_redis.cpp @@ -13,7 +13,9 @@ using namespace Redis; class MyRedisService; -class RedisSocket : public BinarySocket, public ConnectionSocket +class RedisSocket + : public BinarySocket + , public ConnectionSocket { size_t ParseReply(Reply &r, const char *buf, size_t l); public: @@ -31,7 +33,8 @@ public: bool Read(const char *buffer, size_t l) override; }; -class Transaction : public Interface +class Transaction + : public Interface { public: std::deque<Interface *> interfaces; @@ -71,7 +74,8 @@ public: } }; -class MyRedisService : public Provider +class MyRedisService + : public Provider { public: Anope::string host; @@ -516,7 +520,8 @@ bool RedisSocket::Read(const char *buffer, size_t l) } -class ModuleRedis : public Module +class ModuleRedis + : public Module { std::map<Anope::string, MyRedisService *> services; diff --git a/modules/m_rewrite.cpp b/modules/m_rewrite.cpp index 45bd001eb..967913926 100644 --- a/modules/m_rewrite.cpp +++ b/modules/m_rewrite.cpp @@ -97,7 +97,8 @@ struct Rewrite std::vector<Rewrite> Rewrite::rewrites; -class RewriteCommand : public Command +class RewriteCommand + : public Command { public: RewriteCommand(Module *creator) : Command(creator, "rewrite", 0, 0) { } @@ -145,7 +146,8 @@ public: } }; -class ModuleRewrite : public Module +class ModuleRewrite + : public Module { RewriteCommand cmdrewrite; diff --git a/modules/m_sasl.cpp b/modules/m_sasl.cpp index 1951fb66c..a90a70e67 100644 --- a/modules/m_sasl.cpp +++ b/modules/m_sasl.cpp @@ -12,7 +12,8 @@ using namespace SASL; -class Plain : public Mechanism +class Plain + : public Mechanism { public: Plain(Module *o) : Mechanism(o, "PLAIN") { } @@ -72,11 +73,13 @@ public: } }; -class External : public Mechanism +class External + : public Mechanism { ServiceReference<CertService> certs; - struct Session : SASL::Session + struct Session + : SASL::Session { Anope::string cert; @@ -134,7 +137,8 @@ public: } }; -class Anonymous : public Mechanism +class Anonymous + : public Mechanism { public: Anonymous(Module *o) : Mechanism(o, "ANONYMOUS") { } @@ -170,7 +174,9 @@ public: } }; -class SASLService : public SASL::Service, public Timer +class SASLService + : public SASL::Service + , public Timer { std::map<Anope::string, SASL::Session *> sessions; @@ -347,7 +353,8 @@ public: } }; -class ModuleSASL : public Module +class ModuleSASL + : public Module { SASLService sasl; diff --git a/modules/m_xmlrpc.cpp b/modules/m_xmlrpc.cpp index 141151246..7c9f8ce9a 100644 --- a/modules/m_xmlrpc.cpp +++ b/modules/m_xmlrpc.cpp @@ -32,7 +32,9 @@ special[] = { special_chars("", "") }; -class MyXMLRPCServiceInterface : public XMLRPCServiceInterface, public HTTPPage +class MyXMLRPCServiceInterface + : public XMLRPCServiceInterface + , public HTTPPage { std::deque<XMLRPCEvent *> events; @@ -194,7 +196,8 @@ public: } }; -class ModuleXMLRPC : public Module +class ModuleXMLRPC + : public Module { ServiceReference<HTTPProvider> httpref; public: diff --git a/modules/m_xmlrpc_main.cpp b/modules/m_xmlrpc_main.cpp index 3f7ab71d0..f7e499714 100644 --- a/modules/m_xmlrpc_main.cpp +++ b/modules/m_xmlrpc_main.cpp @@ -11,7 +11,8 @@ static Module *me; -class XMLRPCIdentifyRequest : public IdentifyRequest +class XMLRPCIdentifyRequest + : public IdentifyRequest { XMLRPCRequest request; HTTPReply repl; /* Request holds a reference to the HTTPReply, because we might exist long enough to invalidate it @@ -50,7 +51,8 @@ public: } }; -class MyXMLRPCEvent : public XMLRPCEvent +class MyXMLRPCEvent + : public XMLRPCEvent { public: bool Run(XMLRPCServiceInterface *iface, HTTPClient *client, XMLRPCRequest &request) override @@ -95,7 +97,8 @@ private: Anope::string out; - struct XMLRPCommandReply : CommandReply + struct XMLRPCommandReply + : CommandReply { Anope::string &str; @@ -275,7 +278,8 @@ private: } }; -class ModuleXMLRPCMain : public Module +class ModuleXMLRPCMain + : public Module { ServiceReference<XMLRPCServiceInterface> xmlrpc; diff --git a/modules/ns_maxemail.cpp b/modules/ns_maxemail.cpp index 18747aa75..bf7034cd4 100644 --- a/modules/ns_maxemail.cpp +++ b/modules/ns_maxemail.cpp @@ -12,7 +12,8 @@ #include "module.h" -class NSMaxEmail : public Module +class NSMaxEmail + : public Module { bool clean = false; diff --git a/modules/protocol/bahamut.cpp b/modules/protocol/bahamut.cpp index 802069f96..278fc6545 100644 --- a/modules/protocol/bahamut.cpp +++ b/modules/protocol/bahamut.cpp @@ -11,7 +11,8 @@ #include "module.h" -class ChannelModeFlood : public ChannelModeParam +class ChannelModeFlood + : public ChannelModeParam { public: ChannelModeFlood(char modeChar, bool minusNoArg) : ChannelModeParam("FLOOD", modeChar, minusNoArg) { } @@ -30,7 +31,8 @@ public: } }; -class BahamutIRCdProto : public IRCDProto +class BahamutIRCdProto + : public IRCDProto { public: BahamutIRCdProto(Module *creator) : IRCDProto(creator, "Bahamut 1.8.x") @@ -290,7 +292,8 @@ public: } }; -struct IRCDMessageBurst : IRCDMessage +struct IRCDMessageBurst + : IRCDMessage { IRCDMessageBurst(Module *creator) : IRCDMessage(creator, "BURST", 0) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -308,7 +311,8 @@ struct IRCDMessageBurst : IRCDMessage } }; -struct IRCDMessageMode : IRCDMessage +struct IRCDMessageMode + : IRCDMessage { IRCDMessageMode(Module *creator, const Anope::string &sname) : IRCDMessage(creator, sname, 2) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -359,7 +363,8 @@ struct IRCDMessageMode : IRCDMessage ** parv[0] = new nickname ** parv[1] = hopcount */ -struct IRCDMessageNick : IRCDMessage +struct IRCDMessageNick + : IRCDMessage { IRCDMessageNick(Module *creator) : IRCDMessage(creator, "NICK", 2) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -392,7 +397,8 @@ struct IRCDMessageNick : IRCDMessage } }; -struct IRCDMessageServer : IRCDMessage +struct IRCDMessageServer + : IRCDMessage { IRCDMessageServer(Module *creator) : IRCDMessage(creator, "SERVER", 3) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -403,7 +409,8 @@ struct IRCDMessageServer : IRCDMessage } }; -struct IRCDMessageSJoin : IRCDMessage +struct IRCDMessageSJoin + : IRCDMessage { IRCDMessageSJoin(Module *creator) : IRCDMessage(creator, "SJOIN", 2) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -459,7 +466,8 @@ struct IRCDMessageSJoin : IRCDMessage } }; -struct IRCDMessageTopic : IRCDMessage +struct IRCDMessageTopic + : IRCDMessage { IRCDMessageTopic(Module *creator) : IRCDMessage(creator, "TOPIC", 4) { } @@ -471,7 +479,8 @@ struct IRCDMessageTopic : IRCDMessage } }; -class ProtoBahamut : public Module +class ProtoBahamut + : public Module { BahamutIRCdProto ircd_proto; diff --git a/modules/protocol/hybrid.cpp b/modules/protocol/hybrid.cpp index f99e8de80..fb9bfa692 100644 --- a/modules/protocol/hybrid.cpp +++ b/modules/protocol/hybrid.cpp @@ -15,7 +15,8 @@ static Anope::string UplinkSID; static bool UseSVSAccount = false; // Temporary backwards compatibility hack until old proto is deprecated -class HybridProto : public IRCDProto +class HybridProto + : public IRCDProto { void SendSVSKillInternal(const MessageSource &source, User *u, const Anope::string &buf) override { @@ -317,7 +318,8 @@ public: } }; -struct IRCDMessageBMask : IRCDMessage +struct IRCDMessageBMask + : IRCDMessage { IRCDMessageBMask(Module *creator) : IRCDMessage(creator, "BMASK", 4) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -339,7 +341,8 @@ struct IRCDMessageBMask : IRCDMessage } }; -struct IRCDMessageCapab : Message::Capab +struct IRCDMessageCapab + : Message::Capab { IRCDMessageCapab(Module *creator) : Message::Capab(creator, "CAPAB") { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -379,7 +382,8 @@ struct IRCDMessageCertFP: IRCDMessage } }; -struct IRCDMessageEOB : IRCDMessage +struct IRCDMessageEOB + : IRCDMessage { IRCDMessageEOB(Module *creator) : IRCDMessage(creator, "EOB", 0) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -389,7 +393,8 @@ struct IRCDMessageEOB : IRCDMessage } }; -struct IRCDMessageJoin : Message::Join +struct IRCDMessageJoin + : Message::Join { IRCDMessageJoin(Module *creator) : Message::Join(creator, "JOIN") { } @@ -405,7 +410,8 @@ struct IRCDMessageJoin : Message::Join } }; -struct IRCDMessageMetadata : IRCDMessage +struct IRCDMessageMetadata + : IRCDMessage { IRCDMessageMetadata(Module *creator) : IRCDMessage(creator, "METADATA", 3) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -431,7 +437,8 @@ struct IRCDMessageMetadata : IRCDMessage } }; -struct IRCDMessageMLock : IRCDMessage +struct IRCDMessageMLock + : IRCDMessage { IRCDMessageMLock(Module *creator) : IRCDMessage(creator, "MLOCK", 4) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -456,7 +463,8 @@ struct IRCDMessageMLock : IRCDMessage } }; -struct IRCDMessageNick : IRCDMessage +struct IRCDMessageNick + : IRCDMessage { IRCDMessageNick(Module *creator) : IRCDMessage(creator, "NICK", 2) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -468,7 +476,8 @@ struct IRCDMessageNick : IRCDMessage } }; -struct IRCDMessagePass : IRCDMessage +struct IRCDMessagePass + : IRCDMessage { IRCDMessagePass(Module *creator) : IRCDMessage(creator, "PASS", 1) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -481,7 +490,8 @@ struct IRCDMessagePass : IRCDMessage } }; -struct IRCDMessagePong : IRCDMessage +struct IRCDMessagePong + : IRCDMessage { IRCDMessagePong(Module *creator) : IRCDMessage(creator, "PONG", 0) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -491,7 +501,8 @@ struct IRCDMessagePong : IRCDMessage } }; -struct IRCDMessageServer : IRCDMessage +struct IRCDMessageServer + : IRCDMessage { IRCDMessageServer(Module *creator) : IRCDMessage(creator, "SERVER", 3) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -515,7 +526,8 @@ struct IRCDMessageServer : IRCDMessage } }; -struct IRCDMessageSID : IRCDMessage +struct IRCDMessageSID + : IRCDMessage { IRCDMessageSID(Module *creator) : IRCDMessage(creator, "SID", 5) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -530,7 +542,8 @@ struct IRCDMessageSID : IRCDMessage } }; -struct IRCDMessageSJoin : IRCDMessage +struct IRCDMessageSJoin + : IRCDMessage { IRCDMessageSJoin(Module *creator) : IRCDMessage(creator, "SJOIN", 4) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -577,7 +590,8 @@ struct IRCDMessageSJoin : IRCDMessage } }; -struct IRCDMessageSVSMode : IRCDMessage +struct IRCDMessageSVSMode + : IRCDMessage { IRCDMessageSVSMode(Module *creator) : IRCDMessage(creator, "SVSMODE", 3) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -597,7 +611,8 @@ struct IRCDMessageSVSMode : IRCDMessage } }; -struct IRCDMessageTBurst : IRCDMessage +struct IRCDMessageTBurst + : IRCDMessage { IRCDMessageTBurst(Module *creator) : IRCDMessage(creator, "TBURST", 5) { } @@ -615,7 +630,8 @@ struct IRCDMessageTBurst : IRCDMessage } }; -struct IRCDMessageTMode : IRCDMessage +struct IRCDMessageTMode + : IRCDMessage { IRCDMessageTMode(Module *creator) : IRCDMessage(creator, "TMODE", 3) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -642,7 +658,8 @@ struct IRCDMessageTMode : IRCDMessage } }; -struct IRCDMessageUID : IRCDMessage +struct IRCDMessageUID + : IRCDMessage { IRCDMessageUID(Module *creator) : IRCDMessage(creator, "UID", 11) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -662,7 +679,8 @@ struct IRCDMessageUID : IRCDMessage } }; -class ProtoHybrid : public Module +class ProtoHybrid + : public Module { HybridProto ircd_proto; diff --git a/modules/protocol/inspircd.cpp b/modules/protocol/inspircd.cpp index 9691aa367..7de36d956 100644 --- a/modules/protocol/inspircd.cpp +++ b/modules/protocol/inspircd.cpp @@ -44,7 +44,8 @@ static void ParseModule(const Anope::string &module, Anope::string &modname, Ano Log(LOG_DEBUG) << "Parsed module: " << "name=" << modname << " data=" << moddata; } -class InspIRCdProto : public IRCDProto +class InspIRCdProto + : public IRCDProto { private: void SendChgIdentInternal(const Anope::string &nick, const Anope::string &vIdent) @@ -536,7 +537,8 @@ public: } }; -class InspIRCdAutoOpMode : public ChannelModeList +class InspIRCdAutoOpMode + : public ChannelModeList { public: InspIRCdAutoOpMode(char mode) : ChannelModeList("AUTOOP", mode) @@ -551,7 +553,8 @@ public: } }; -class InspIRCdExtBan : public ChannelModeVirtual<ChannelModeList> +class InspIRCdExtBan + : public ChannelModeVirtual<ChannelModeList> { char ext; @@ -579,7 +582,8 @@ public: namespace InspIRCdExtban { - class EntryMatcher : public InspIRCdExtBan + class EntryMatcher + : public InspIRCdExtBan { public: EntryMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : InspIRCdExtBan(mname, mbase, c) @@ -595,7 +599,8 @@ namespace InspIRCdExtban } }; - class ChannelMatcher : public InspIRCdExtBan + class ChannelMatcher + : public InspIRCdExtBan { public: ChannelMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : InspIRCdExtBan(mname, mbase, c) @@ -631,7 +636,8 @@ namespace InspIRCdExtban } }; - class AccountMatcher : public InspIRCdExtBan + class AccountMatcher + : public InspIRCdExtBan { public: AccountMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : InspIRCdExtBan(mname, mbase, c) @@ -647,7 +653,8 @@ namespace InspIRCdExtban } }; - class RealnameMatcher : public InspIRCdExtBan + class RealnameMatcher + : public InspIRCdExtBan { public: RealnameMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : InspIRCdExtBan(mname, mbase, c) @@ -662,7 +669,8 @@ namespace InspIRCdExtban } }; - class ServerMatcher : public InspIRCdExtBan + class ServerMatcher + : public InspIRCdExtBan { public: ServerMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : InspIRCdExtBan(mname, mbase, c) @@ -677,7 +685,8 @@ namespace InspIRCdExtban } }; - class FingerprintMatcher : public InspIRCdExtBan + class FingerprintMatcher + : public InspIRCdExtBan { public: FingerprintMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : InspIRCdExtBan(mname, mbase, c) @@ -692,7 +701,8 @@ namespace InspIRCdExtban } }; - class UnidentifiedMatcher : public InspIRCdExtBan + class UnidentifiedMatcher + : public InspIRCdExtBan { public: UnidentifiedMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : InspIRCdExtBan(mname, mbase, c) @@ -708,7 +718,8 @@ namespace InspIRCdExtban }; } -class ColonDelimitedParamMode : public ChannelModeParam +class ColonDelimitedParamMode + : public ChannelModeParam { public: ColonDelimitedParamMode(const Anope::string &modename, char modeChar) : ChannelModeParam(modename, modeChar, true) { } @@ -757,7 +768,8 @@ public: } }; -class SimpleNumberParamMode : public ChannelModeParam +class SimpleNumberParamMode + : public ChannelModeParam { public: SimpleNumberParamMode(const Anope::string &modename, char modeChar) : ChannelModeParam(modename, modeChar, true) { } @@ -782,7 +794,8 @@ public: } }; -class ChannelModeFlood : public ColonDelimitedParamMode +class ChannelModeFlood + : public ColonDelimitedParamMode { public: ChannelModeFlood(char modeChar) : ColonDelimitedParamMode("FLOOD", modeChar) { } @@ -796,7 +809,8 @@ public: } }; -class ChannelModeHistory : public ColonDelimitedParamMode +class ChannelModeHistory + : public ColonDelimitedParamMode { public: ChannelModeHistory(char modeChar) : ColonDelimitedParamMode("HISTORY", modeChar) { } @@ -807,7 +821,8 @@ public: } }; -class ChannelModeRedirect : public ChannelModeParam +class ChannelModeRedirect + : public ChannelModeParam { public: ChannelModeRedirect(char modeChar) : ChannelModeParam("REDIRECT", modeChar, true) { } @@ -819,7 +834,8 @@ public: } }; -struct IRCDMessageAway : Message::Away +struct IRCDMessageAway + : Message::Away { IRCDMessageAway(Module *creator) : Message::Away(creator, "AWAY") { SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -833,7 +849,8 @@ struct IRCDMessageAway : Message::Away } }; -struct IRCDMessageCapab : Message::Capab +struct IRCDMessageCapab + : Message::Capab { struct ModeInfo { @@ -1225,7 +1242,8 @@ struct IRCDMessageCapab : Message::Capab } }; -struct IRCDMessageEncap : IRCDMessage +struct IRCDMessageEncap + : IRCDMessage { IRCDMessageEncap(Module *creator) : IRCDMessage(creator, "ENCAP", 4) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1275,7 +1293,8 @@ struct IRCDMessageEncap : IRCDMessage } }; -struct IRCDMessageFHost : IRCDMessage +struct IRCDMessageFHost + : IRCDMessage { IRCDMessageFHost(Module *creator) : IRCDMessage(creator, "FHOST", 1) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -1288,7 +1307,8 @@ struct IRCDMessageFHost : IRCDMessage } }; -struct IRCDMessageFIdent : IRCDMessage +struct IRCDMessageFIdent + : IRCDMessage { IRCDMessageFIdent(Module *creator) : IRCDMessage(creator, "FIDENT", 1) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -1298,7 +1318,8 @@ struct IRCDMessageFIdent : IRCDMessage } }; -struct IRCDMessageKick : IRCDMessage +struct IRCDMessageKick + : IRCDMessage { IRCDMessageKick(Module *creator) : IRCDMessage(creator, "KICK", 3) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1315,7 +1336,8 @@ struct IRCDMessageKick : IRCDMessage } }; -struct IRCDMessageSave : IRCDMessage +struct IRCDMessageSave + : IRCDMessage { time_t last_collide = 0; @@ -1357,7 +1379,8 @@ struct IRCDMessageSave : IRCDMessage } }; -class IRCDMessageMetadata : IRCDMessage +class IRCDMessageMetadata + : IRCDMessage { const bool &do_topiclock; const bool &do_mlock; @@ -1508,7 +1531,8 @@ public: } }; -struct IRCDMessageEndburst : IRCDMessage +struct IRCDMessageEndburst + : IRCDMessage { IRCDMessageEndburst(Module *creator) : IRCDMessage(creator, "ENDBURST", 0) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -1522,7 +1546,8 @@ struct IRCDMessageEndburst : IRCDMessage } }; -struct IRCDMessageFJoin : IRCDMessage +struct IRCDMessageFJoin + : IRCDMessage { IRCDMessageFJoin(Module *creator) : IRCDMessage(creator, "FJOIN", 2) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1578,7 +1603,8 @@ struct IRCDMessageFJoin : IRCDMessage } }; -struct IRCDMessageFMode : IRCDMessage +struct IRCDMessageFMode + : IRCDMessage { IRCDMessageFMode(Module *creator) : IRCDMessage(creator, "FMODE", 3) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1607,7 +1633,8 @@ struct IRCDMessageFMode : IRCDMessage } }; -struct IRCDMessageFTopic : IRCDMessage +struct IRCDMessageFTopic + : IRCDMessage { IRCDMessageFTopic(Module *creator) : IRCDMessage(creator, "FTOPIC", 4) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1625,7 +1652,8 @@ struct IRCDMessageFTopic : IRCDMessage } }; -struct IRCDMessageIdle : IRCDMessage +struct IRCDMessageIdle + : IRCDMessage { IRCDMessageIdle(Module *creator) : IRCDMessage(creator, "IDLE", 1) { } @@ -1643,7 +1671,8 @@ struct IRCDMessageIdle : IRCDMessage } }; -struct IRCDMessageIJoin : IRCDMessage +struct IRCDMessageIJoin + : IRCDMessage { IRCDMessageIJoin(Module *creator) : IRCDMessage(creator, "IJOIN", 2) { SetFlag(IRCDMESSAGE_REQUIRE_USER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1679,7 +1708,8 @@ struct IRCDMessageIJoin : IRCDMessage } }; -struct IRCDMessageMode : IRCDMessage +struct IRCDMessageMode + : IRCDMessage { IRCDMessageMode(Module *creator) : IRCDMessage(creator, "MODE", 2) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1709,7 +1739,8 @@ struct IRCDMessageMode : IRCDMessage } }; -struct IRCDMessageNick : IRCDMessage +struct IRCDMessageNick + : IRCDMessage { IRCDMessageNick(Module *creator) : IRCDMessage(creator, "NICK", 2) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -1719,7 +1750,8 @@ struct IRCDMessageNick : IRCDMessage } }; -struct IRCDMessageOperType : IRCDMessage +struct IRCDMessageOperType + : IRCDMessage { IRCDMessageOperType(Module *creator) : IRCDMessage(creator, "OPERTYPE", 0) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -1733,7 +1765,8 @@ struct IRCDMessageOperType : IRCDMessage } }; -struct IRCDMessagePing : IRCDMessage +struct IRCDMessagePing + : IRCDMessage { IRCDMessagePing(Module *creator) : IRCDMessage(creator, "PING", 1) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -1744,7 +1777,8 @@ struct IRCDMessagePing : IRCDMessage } }; -struct IRCDMessageRSQuit : IRCDMessage +struct IRCDMessageRSQuit + : IRCDMessage { IRCDMessageRSQuit(Module *creator) : IRCDMessage(creator, "RSQUIT", 1) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1760,7 +1794,8 @@ struct IRCDMessageRSQuit : IRCDMessage } }; -struct IRCDMessageServer : IRCDMessage +struct IRCDMessageServer + : IRCDMessage { IRCDMessageServer(Module *creator) : IRCDMessage(creator, "SERVER", 3) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1793,7 +1828,8 @@ struct IRCDMessageServer : IRCDMessage } }; -struct IRCDMessageSQuit : Message::SQuit +struct IRCDMessageSQuit + : Message::SQuit { IRCDMessageSQuit(Module *creator) : Message::SQuit(creator) { } @@ -1815,7 +1851,8 @@ struct IRCDMessageSQuit : Message::SQuit } }; -struct IRCDMessageTime : IRCDMessage +struct IRCDMessageTime + : IRCDMessage { IRCDMessageTime(Module *creator) : IRCDMessage(creator, "TIME", 2) { } @@ -1825,7 +1862,8 @@ struct IRCDMessageTime : IRCDMessage } }; -struct IRCDMessageUID : IRCDMessage +struct IRCDMessageUID + : IRCDMessage { IRCDMessageUID(Module *creator) : IRCDMessage(creator, "UID", 8) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1873,7 +1911,8 @@ struct IRCDMessageUID : IRCDMessage } }; -class ProtoInspIRCd : public Module +class ProtoInspIRCd + : public Module { InspIRCdProto ircd_proto; ExtensibleItem<bool> ssl; diff --git a/modules/protocol/ngircd.cpp b/modules/protocol/ngircd.cpp index bb280db46..587185e42 100644 --- a/modules/protocol/ngircd.cpp +++ b/modules/protocol/ngircd.cpp @@ -11,7 +11,8 @@ #include "module.h" -class ngIRCdProto : public IRCDProto +class ngIRCdProto + : public IRCDProto { void SendSVSKillInternal(const MessageSource &source, User *user, const Anope::string &buf) override { @@ -146,7 +147,8 @@ public: } }; -struct IRCDMessage005 : IRCDMessage +struct IRCDMessage005 + : IRCDMessage { IRCDMessage005(Module *creator) : IRCDMessage(creator, "005", 1) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -180,7 +182,8 @@ struct IRCDMessage005 : IRCDMessage } }; -struct IRCDMessage376 : IRCDMessage +struct IRCDMessage376 + : IRCDMessage { IRCDMessage376(Module *creator) : IRCDMessage(creator, "376", 2) { } @@ -197,7 +200,8 @@ struct IRCDMessage376 : IRCDMessage } }; -struct IRCDMessageChaninfo : IRCDMessage +struct IRCDMessageChaninfo + : IRCDMessage { IRCDMessageChaninfo(Module *creator) : IRCDMessage(creator, "CHANINFO", 2) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -250,7 +254,8 @@ struct IRCDMessageChaninfo : IRCDMessage } }; -struct IRCDMessageJoin : Message::Join +struct IRCDMessageJoin + : Message::Join { IRCDMessageJoin(Module *creator) : Message::Join(creator, "JOIN") { SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -290,7 +295,8 @@ struct IRCDMessageJoin : Message::Join } }; -struct IRCDMessageMetadata : IRCDMessage +struct IRCDMessageMetadata + : IRCDMessage { IRCDMessageMetadata(Module *creator) : IRCDMessage(creator, "METADATA", 3) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -349,7 +355,8 @@ struct IRCDMessageMetadata : IRCDMessage } }; -struct IRCDMessageMode : IRCDMessage +struct IRCDMessageMode + : IRCDMessage { IRCDMessageMode(Module *creator) : IRCDMessage(creator, "MODE", 2) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -385,7 +392,8 @@ struct IRCDMessageMode : IRCDMessage } }; -struct IRCDMessageNick : IRCDMessage +struct IRCDMessageNick + : IRCDMessage { IRCDMessageNick(Module *creator) : IRCDMessage(creator, "NICK", 1) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -437,7 +445,8 @@ struct IRCDMessageNick : IRCDMessage } }; -struct IRCDMessageNJoin : IRCDMessage +struct IRCDMessageNJoin + : IRCDMessage { IRCDMessageNJoin(Module *creator) : IRCDMessage(creator, "NJOIN",2) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); }; @@ -483,7 +492,8 @@ struct IRCDMessageNJoin : IRCDMessage } }; -struct IRCDMessagePong : IRCDMessage +struct IRCDMessagePong + : IRCDMessage { IRCDMessagePong(Module *creator) : IRCDMessage(creator, "PONG", 0) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -499,7 +509,8 @@ struct IRCDMessagePong : IRCDMessage } }; -struct IRCDMessageServer : IRCDMessage +struct IRCDMessageServer + : IRCDMessage { IRCDMessageServer(Module *creator) : IRCDMessage(creator, "SERVER", 3) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -550,7 +561,8 @@ struct IRCDMessageServer : IRCDMessage } }; -struct IRCDMessageTopic : IRCDMessage +struct IRCDMessageTopic + : IRCDMessage { IRCDMessageTopic(Module *creator) : IRCDMessage(creator, "TOPIC", 2) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -569,7 +581,8 @@ struct IRCDMessageTopic : IRCDMessage -class ProtongIRCd : public Module +class ProtongIRCd + : public Module { ngIRCdProto ircd_proto; diff --git a/modules/protocol/plexus.cpp b/modules/protocol/plexus.cpp index 8eedc2445..eb98f8f9c 100644 --- a/modules/protocol/plexus.cpp +++ b/modules/protocol/plexus.cpp @@ -16,7 +16,8 @@ static Anope::string UplinkSID; static ServiceReference<IRCDProto> hybrid("IRCDProto", "hybrid"); -class PlexusProto : public IRCDProto +class PlexusProto + : public IRCDProto { public: PlexusProto(Module *creator) : IRCDProto(creator, "hybrid-7.2.3+plexus-3.0.1") @@ -187,7 +188,8 @@ public: } }; -struct IRCDMessageEncap : IRCDMessage +struct IRCDMessageEncap + : IRCDMessage { IRCDMessageEncap(Module *creator) : IRCDMessage(creator, "ENCAP", 4) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -243,7 +245,8 @@ struct IRCDMessageEncap : IRCDMessage } }; -struct IRCDMessagePass : IRCDMessage +struct IRCDMessagePass + : IRCDMessage { IRCDMessagePass(Module *creator) : IRCDMessage(creator, "PASS", 4) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -253,7 +256,8 @@ struct IRCDMessagePass : IRCDMessage } }; -struct IRCDMessageServer : IRCDMessage +struct IRCDMessageServer + : IRCDMessage { IRCDMessageServer(Module *creator) : IRCDMessage(creator, "SERVER", 3) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -269,7 +273,8 @@ struct IRCDMessageServer : IRCDMessage } }; -struct IRCDMessageUID : IRCDMessage +struct IRCDMessageUID + : IRCDMessage { IRCDMessageUID(Module *creator) : IRCDMessage(creator, "UID", 11) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -318,7 +323,8 @@ struct IRCDMessageUID : IRCDMessage } }; -class ProtoPlexus : public Module +class ProtoPlexus + : public Module { Module *m_hybrid; diff --git a/modules/protocol/ratbox.cpp b/modules/protocol/ratbox.cpp index c7f4c0dad..9ba815c4d 100644 --- a/modules/protocol/ratbox.cpp +++ b/modules/protocol/ratbox.cpp @@ -15,7 +15,8 @@ static Anope::string UplinkSID; static ServiceReference<IRCDProto> hybrid("IRCDProto", "hybrid"); -class RatboxProto : public IRCDProto +class RatboxProto + : public IRCDProto { BotInfo *FindIntroduced() { @@ -140,7 +141,8 @@ public: } }; -struct IRCDMessageEncap : IRCDMessage +struct IRCDMessageEncap + : IRCDMessage { IRCDMessageEncap(Module *creator) : IRCDMessage(creator, "ENCAP", 3) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -165,7 +167,8 @@ struct IRCDMessageEncap : IRCDMessage } }; -struct IRCDMessageJoin : Message::Join +struct IRCDMessageJoin + : Message::Join { IRCDMessageJoin(Module *creator) : Message::Join(creator, "JOIN") { } @@ -184,7 +187,8 @@ struct IRCDMessageJoin : Message::Join } }; -struct IRCDMessagePass : IRCDMessage +struct IRCDMessagePass + : IRCDMessage { IRCDMessagePass(Module *creator) : IRCDMessage(creator, "PASS", 4) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -194,7 +198,8 @@ struct IRCDMessagePass : IRCDMessage } }; -struct IRCDMessageServer : IRCDMessage +struct IRCDMessageServer + : IRCDMessage { IRCDMessageServer(Module *creator) : IRCDMessage(creator, "SERVER", 3) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -209,7 +214,8 @@ struct IRCDMessageServer : IRCDMessage } }; -struct IRCDMessageTBurst : IRCDMessage +struct IRCDMessageTBurst + : IRCDMessage { IRCDMessageTBurst(Module *creator) : IRCDMessage(creator, "TB", 3) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -234,7 +240,8 @@ struct IRCDMessageTBurst : IRCDMessage } }; -struct IRCDMessageUID : IRCDMessage +struct IRCDMessageUID + : IRCDMessage { IRCDMessageUID(Module *creator) : IRCDMessage(creator, "UID", 9) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -246,7 +253,8 @@ struct IRCDMessageUID : IRCDMessage } }; -class ProtoRatbox : public Module +class ProtoRatbox + : public Module { Module *m_hybrid; diff --git a/modules/protocol/solanum.cpp b/modules/protocol/solanum.cpp index 56e87336c..763173342 100644 --- a/modules/protocol/solanum.cpp +++ b/modules/protocol/solanum.cpp @@ -17,7 +17,8 @@ static Anope::string UplinkSID; static ServiceReference<IRCDProto> ratbox("IRCDProto", "ratbox"); -class ChannelModeLargeBan : public ChannelMode +class ChannelModeLargeBan + : public ChannelMode { public: ChannelModeLargeBan(const Anope::string &mname, char modeChar) : ChannelMode(mname, modeChar) { } @@ -29,7 +30,8 @@ public: }; -class SolanumProto : public IRCDProto +class SolanumProto + : public IRCDProto { public: @@ -170,7 +172,8 @@ public: }; -struct IRCDMessageEncap : IRCDMessage +struct IRCDMessageEncap + : IRCDMessage { IRCDMessageEncap(Module *creator) : IRCDMessage(creator, "ENCAP", 3) { @@ -226,7 +229,8 @@ struct IRCDMessageEncap : IRCDMessage } }; -struct IRCDMessageEUID : IRCDMessage +struct IRCDMessageEUID + : IRCDMessage { IRCDMessageEUID(Module *creator) : IRCDMessage(creator, "EUID", 11) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -254,7 +258,8 @@ struct IRCDMessageEUID : IRCDMessage }; // we can't use this function from ratbox because we set a local variable here -struct IRCDMessageServer : IRCDMessage +struct IRCDMessageServer + : IRCDMessage { IRCDMessageServer(Module *creator) : IRCDMessage(creator, "SERVER", 3) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -270,7 +275,8 @@ struct IRCDMessageServer : IRCDMessage }; // we can't use this function from ratbox because we set a local variable here -struct IRCDMessagePass : IRCDMessage +struct IRCDMessagePass + : IRCDMessage { IRCDMessagePass(Module *creator) : IRCDMessage(creator, "PASS", 4) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -281,7 +287,8 @@ struct IRCDMessagePass : IRCDMessage } }; -struct IRCDMessageNotice : Message::Notice +struct IRCDMessageNotice + : Message::Notice { IRCDMessageNotice(Module *creator) : Message::Notice(creator) { } @@ -294,7 +301,8 @@ struct IRCDMessageNotice : Message::Notice } }; -struct IRCDMessagePrivmsg : Message::Privmsg +struct IRCDMessagePrivmsg + : Message::Privmsg { IRCDMessagePrivmsg(Module *creator) : Message::Privmsg(creator) { } @@ -307,7 +315,8 @@ struct IRCDMessagePrivmsg : Message::Privmsg } }; -class ProtoSolanum : public Module +class ProtoSolanum + : public Module { Module *m_ratbox; diff --git a/modules/protocol/unrealircd.cpp b/modules/protocol/unrealircd.cpp index 30591761e..0cf472e21 100644 --- a/modules/protocol/unrealircd.cpp +++ b/modules/protocol/unrealircd.cpp @@ -16,7 +16,8 @@ typedef Anope::map<Anope::string> ModData; static Anope::string UplinkSID; -class UnrealIRCdProto : public IRCDProto +class UnrealIRCdProto + : public IRCDProto { public: PrimitiveExtensibleItem<ModData> ClientModData; @@ -432,7 +433,8 @@ private: } }; -class UnrealExtBan : public ChannelModeVirtual<ChannelModeList> +class UnrealExtBan + : public ChannelModeVirtual<ChannelModeList> { char ext; @@ -460,7 +462,8 @@ public: namespace UnrealExtban { - class ChannelMatcher : public UnrealExtBan + class ChannelMatcher + : public UnrealExtBan { public: ChannelMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : UnrealExtBan(mname, mbase, c) @@ -495,7 +498,8 @@ namespace UnrealExtban } }; - class EntryMatcher : public UnrealExtBan + class EntryMatcher + : public UnrealExtBan { public: EntryMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : UnrealExtBan(mname, mbase, c) @@ -511,7 +515,8 @@ namespace UnrealExtban } }; - class RealnameMatcher : public UnrealExtBan + class RealnameMatcher + : public UnrealExtBan { public: RealnameMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : UnrealExtBan(mname, mbase, c) @@ -527,7 +532,8 @@ namespace UnrealExtban } }; - class RegisteredMatcher : public UnrealExtBan + class RegisteredMatcher + : public UnrealExtBan { public: RegisteredMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : UnrealExtBan(mname, mbase, c) @@ -541,7 +547,8 @@ namespace UnrealExtban } }; - class AccountMatcher : public UnrealExtBan + class AccountMatcher + : public UnrealExtBan { public: AccountMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : UnrealExtBan(mname, mbase, c) @@ -560,7 +567,8 @@ namespace UnrealExtban } }; - class FingerprintMatcher : public UnrealExtBan + class FingerprintMatcher + : public UnrealExtBan { public: FingerprintMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : UnrealExtBan(mname, mbase, c) @@ -575,7 +583,8 @@ namespace UnrealExtban } }; - class OperclassMatcher : public UnrealExtBan + class OperclassMatcher + : public UnrealExtBan { public: OperclassMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : UnrealExtBan(mname, mbase, c) @@ -591,7 +600,8 @@ namespace UnrealExtban } }; - class TimedBanMatcher : public UnrealExtBan + class TimedBanMatcher + : public UnrealExtBan { public: TimedBanMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : UnrealExtBan(mname, mbase, c) @@ -608,7 +618,8 @@ namespace UnrealExtban } }; - class CountryMatcher : public UnrealExtBan + class CountryMatcher + : public UnrealExtBan { public: CountryMatcher(const Anope::string &mname, const Anope::string &mbase, char c) : UnrealExtBan(mname, mbase, c) @@ -635,7 +646,8 @@ namespace UnrealExtban }; } -class ChannelModeFlood : public ChannelModeParam +class ChannelModeFlood + : public ChannelModeParam { public: ChannelModeFlood(char modeChar, bool minusNoArg) : ChannelModeParam("FLOOD", modeChar, minusNoArg) { } @@ -686,7 +698,8 @@ public: } }; -class ChannelModeHistory : public ChannelModeParam /* stolen from inspircd3's ColonDelimitedParamMode */ +class ChannelModeHistory + : public ChannelModeParam { public: ChannelModeHistory(char modeChar) : ChannelModeParam("HISTORY", modeChar, true) { } @@ -725,7 +738,8 @@ public: } }; -class ChannelModeUnrealSSL : public ChannelMode +class ChannelModeUnrealSSL + : public ChannelMode { public: ChannelModeUnrealSSL(const Anope::string &n, char c) : ChannelMode(n, c) @@ -738,7 +752,8 @@ public: } }; -struct IRCDMessageCapab : Message::Capab +struct IRCDMessageCapab + : Message::Capab { IRCDMessageCapab(Module *creator) : Message::Capab(creator, "PROTOCTL") { } @@ -1021,7 +1036,8 @@ struct IRCDMessageCapab : Message::Capab } }; -struct IRCDMessageChgHost : IRCDMessage +struct IRCDMessageChgHost + : IRCDMessage { IRCDMessageChgHost(Module *creator) : IRCDMessage(creator, "CHGHOST", 2) { } @@ -1033,7 +1049,8 @@ struct IRCDMessageChgHost : IRCDMessage } }; -struct IRCDMessageChgIdent : IRCDMessage +struct IRCDMessageChgIdent + : IRCDMessage { IRCDMessageChgIdent(Module *creator) : IRCDMessage(creator, "CHGIDENT", 2) { } @@ -1045,7 +1062,8 @@ struct IRCDMessageChgIdent : IRCDMessage } }; -struct IRCDMessageChgName : IRCDMessage +struct IRCDMessageChgName + : IRCDMessage { IRCDMessageChgName(Module *creator) : IRCDMessage(creator, "CHGNAME", 2) { } @@ -1057,7 +1075,8 @@ struct IRCDMessageChgName : IRCDMessage } }; -struct IRCDMessageMD : IRCDMessage +struct IRCDMessageMD + : IRCDMessage { PrimitiveExtensibleItem<ModData> &ClientModData; PrimitiveExtensibleItem<ModData> &ChannelModData; @@ -1123,7 +1142,8 @@ struct IRCDMessageMD : IRCDMessage } }; -struct IRCDMessageMode : IRCDMessage +struct IRCDMessageMode + : IRCDMessage { IRCDMessageMode(Module *creator, const Anope::string &mname) : IRCDMessage(creator, mname, 2) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1168,7 +1188,8 @@ struct IRCDMessageMode : IRCDMessage * argv[6] = free(**) * argv[7] = ircnet */ -struct IRCDMessageNetInfo : IRCDMessage +struct IRCDMessageNetInfo + : IRCDMessage { IRCDMessageNetInfo(Module *creator) : IRCDMessage(creator, "NETINFO", 8) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -1178,7 +1199,8 @@ struct IRCDMessageNetInfo : IRCDMessage } }; -struct IRCDMessageNick : IRCDMessage +struct IRCDMessageNick + : IRCDMessage { IRCDMessageNick(Module *creator) : IRCDMessage(creator, "NICK", 2) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1264,7 +1286,8 @@ struct IRCDMessageNick : IRCDMessage * with their server "not syncing". We now send a PING immediately when receiving a new server * and then finish sync once we get a pong back from that server. */ -struct IRCDMessagePong : IRCDMessage +struct IRCDMessagePong + : IRCDMessage { IRCDMessagePong(Module *creator) : IRCDMessage(creator, "PONG", 0) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -1275,7 +1298,8 @@ struct IRCDMessagePong : IRCDMessage } }; -struct IRCDMessageSASL : IRCDMessage +struct IRCDMessageSASL + : IRCDMessage { IRCDMessageSASL(Module *creator) : IRCDMessage(creator, "SASL", 4) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -1295,7 +1319,8 @@ struct IRCDMessageSASL : IRCDMessage } }; -struct IRCDMessageSDesc : IRCDMessage +struct IRCDMessageSDesc + : IRCDMessage { IRCDMessageSDesc(Module *creator) : IRCDMessage(creator, "SDESC", 1) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -1305,7 +1330,8 @@ struct IRCDMessageSDesc : IRCDMessage } }; -struct IRCDMessageSetHost : IRCDMessage +struct IRCDMessageSetHost + : IRCDMessage { IRCDMessageSetHost(Module *creator) : IRCDMessage(creator, "SETHOST", 1) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -1321,7 +1347,8 @@ struct IRCDMessageSetHost : IRCDMessage } }; -struct IRCDMessageSetIdent : IRCDMessage +struct IRCDMessageSetIdent + : IRCDMessage { IRCDMessageSetIdent(Module *creator) : IRCDMessage(creator, "SETIDENT", 1) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -1332,7 +1359,8 @@ struct IRCDMessageSetIdent : IRCDMessage } }; -struct IRCDMessageSetName : IRCDMessage +struct IRCDMessageSetName + : IRCDMessage { IRCDMessageSetName(Module *creator) : IRCDMessage(creator, "SETNAME", 1) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -1343,7 +1371,8 @@ struct IRCDMessageSetName : IRCDMessage } }; -struct IRCDMessageServer : IRCDMessage +struct IRCDMessageServer + : IRCDMessage { IRCDMessageServer(Module *creator) : IRCDMessage(creator, "SERVER", 3) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -1365,7 +1394,8 @@ struct IRCDMessageServer : IRCDMessage } }; -struct IRCDMessageSID : IRCDMessage +struct IRCDMessageSID + : IRCDMessage { IRCDMessageSID(Module *creator) : IRCDMessage(creator, "SID", 4) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -1392,7 +1422,8 @@ static char UnrealSjoinPrefixToModeChar(char sjoin_prefix) } } -struct IRCDMessageSJoin : IRCDMessage +struct IRCDMessageSJoin + : IRCDMessage { IRCDMessageSJoin(Module *creator) : IRCDMessage(creator, "SJOIN", 3) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); } @@ -1485,7 +1516,8 @@ struct IRCDMessageSJoin : IRCDMessage } }; -class IRCDMessageSVSLogin : IRCDMessage +class IRCDMessageSVSLogin + : IRCDMessage { public: IRCDMessageSVSLogin(Module *creator) : IRCDMessage(creator, "SVSLOGIN", 3) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -1514,7 +1546,8 @@ public: } }; -struct IRCDMessageTopic : IRCDMessage +struct IRCDMessageTopic + : IRCDMessage { IRCDMessageTopic(Module *creator) : IRCDMessage(creator, "TOPIC", 4) { } @@ -1547,7 +1580,8 @@ struct IRCDMessageTopic : IRCDMessage * parv[10] = ip * parv[11] = info */ -struct IRCDMessageUID : IRCDMessage +struct IRCDMessageUID + : IRCDMessage { IRCDMessageUID(Module *creator) : IRCDMessage(creator, "UID", 12) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); } @@ -1616,7 +1650,8 @@ struct IRCDMessageUID : IRCDMessage } }; -struct IRCDMessageUmode2 : IRCDMessage +struct IRCDMessageUmode2 + : IRCDMessage { IRCDMessageUmode2(Module *creator) : IRCDMessage(creator, "UMODE2", 1) { SetFlag(IRCDMESSAGE_REQUIRE_USER); } @@ -1626,7 +1661,8 @@ struct IRCDMessageUmode2 : IRCDMessage } }; -class ProtoUnreal : public Module +class ProtoUnreal + : public Module { UnrealIRCdProto ircd_proto; diff --git a/modules/pseudoclients/botserv.cpp b/modules/pseudoclients/botserv.cpp index 7c28ff706..fb744f643 100644 --- a/modules/pseudoclients/botserv.cpp +++ b/modules/pseudoclients/botserv.cpp @@ -11,7 +11,8 @@ #include "module.h" -class BotServCore : public Module +class BotServCore + : public Module { Reference<BotInfo> BotServ; ExtensibleRef<bool> persist, inhabit; diff --git a/modules/pseudoclients/chanserv.cpp b/modules/pseudoclients/chanserv.cpp index 414fb9cc0..95826ea7b 100644 --- a/modules/pseudoclients/chanserv.cpp +++ b/modules/pseudoclients/chanserv.cpp @@ -19,7 +19,9 @@ inline static Anope::string BotModes() ); } -class ChanServCore : public Module, public ChanServService +class ChanServCore + : public Module + , public ChanServService { Reference<BotInfo> ChanServ; std::vector<Anope::string> defaults; @@ -38,7 +40,8 @@ public: /** A timer used to keep the BotServ bot/ChanServ in the channel * after kicking the last user in a channel */ - class ChanServTimer : public Timer + class ChanServTimer + : public Timer { Reference<BotInfo> &ChanServ; ExtensibleItem<bool> &inhabit; diff --git a/modules/pseudoclients/global.cpp b/modules/pseudoclients/global.cpp index 5ffdf13d9..95359a193 100644 --- a/modules/pseudoclients/global.cpp +++ b/modules/pseudoclients/global.cpp @@ -11,7 +11,9 @@ #include "module.h" -class GlobalCore : public Module, public GlobalService +class GlobalCore + : public Module + , public GlobalService { Reference<BotInfo> Global; diff --git a/modules/pseudoclients/hostserv.cpp b/modules/pseudoclients/hostserv.cpp index 060c504b7..12af0467b 100644 --- a/modules/pseudoclients/hostserv.cpp +++ b/modules/pseudoclients/hostserv.cpp @@ -11,7 +11,8 @@ #include "module.h" -class HostServCore : public Module +class HostServCore + : public Module { Reference<BotInfo> HostServ; public: diff --git a/modules/pseudoclients/memoserv.cpp b/modules/pseudoclients/memoserv.cpp index e3be62c7c..12677dbcf 100644 --- a/modules/pseudoclients/memoserv.cpp +++ b/modules/pseudoclients/memoserv.cpp @@ -11,7 +11,9 @@ #include "module.h" -class MemoServCore : public Module, public MemoServService +class MemoServCore + : public Module + , public MemoServService { Reference<BotInfo> MemoServ; diff --git a/modules/pseudoclients/nickserv.cpp b/modules/pseudoclients/nickserv.cpp index c885d5576..9bf11e268 100644 --- a/modules/pseudoclients/nickserv.cpp +++ b/modules/pseudoclients/nickserv.cpp @@ -16,7 +16,8 @@ static std::set<NickServCollide *> collides; /** Timer for colliding nicks to force people off of nicknames */ -class NickServCollide : public Timer +class NickServCollide + : public Timer { NickServService *service; Reference<User> u; @@ -58,7 +59,8 @@ public: /** Timer for removing HELD status from nicks. */ -class NickServHeld : public Timer +class NickServHeld + : public Timer { Reference<NickAlias> na; Anope::string nick; @@ -80,7 +82,9 @@ static Anope::map<NickServRelease *> NickServReleases; /** Timer for releasing nicks to be available for use */ -class NickServRelease : public User, public Timer +class NickServRelease + : public User + , public Timer { Anope::string nick; @@ -110,7 +114,9 @@ public: void Tick(time_t t) override { } }; -class NickServCore : public Module, public NickServService +class NickServCore + : public Module + , public NickServService { Reference<BotInfo> NickServ; std::vector<Anope::string> defaults; diff --git a/modules/pseudoclients/operserv.cpp b/modules/pseudoclients/operserv.cpp index 9f8e320e0..6e793a599 100644 --- a/modules/pseudoclients/operserv.cpp +++ b/modules/pseudoclients/operserv.cpp @@ -11,7 +11,8 @@ #include "module.h" -class SGLineManager : public XLineManager +class SGLineManager + : public XLineManager { public: SGLineManager(Module *creator) : XLineManager(creator, "xlinemanager/sgline", 'G') { } @@ -63,7 +64,8 @@ public: } }; -class SQLineManager : public XLineManager +class SQLineManager + : public XLineManager { ServiceReference<NickServService> nickserv; @@ -142,7 +144,8 @@ public: } }; -class SNLineManager : public XLineManager +class SNLineManager + : public XLineManager { public: SNLineManager(Module *creator) : XLineManager(creator, "xlinemanager/snline", 'N') { } @@ -180,7 +183,8 @@ public: } }; -class OperServCore : public Module +class OperServCore + : public Module { Reference<BotInfo> OperServ; SGLineManager sglines; diff --git a/modules/stats/cs_fantasy_stats.cpp b/modules/stats/cs_fantasy_stats.cpp index 75e3442ab..a2595c08c 100644 --- a/modules/stats/cs_fantasy_stats.cpp +++ b/modules/stats/cs_fantasy_stats.cpp @@ -12,7 +12,8 @@ #include "module.h" #include "modules/sql.h" -class MySQLInterface : public SQL::Interface +class MySQLInterface + : public SQL::Interface { public: MySQLInterface(Module *o) : SQL::Interface(o) { } @@ -31,7 +32,8 @@ public: }; -class CommandCSStats : public Command +class CommandCSStats + : public Command { public: CommandCSStats(Module *creator) : Command (creator, "chanserv/stats", 0, 2) @@ -43,7 +45,8 @@ public: void Execute(CommandSource &source, const std::vector<Anope::string> ¶ms); }; -class CommandCSGStats : public Command +class CommandCSGStats + : public Command { public: CommandCSGStats(Module *creator) : Command (creator, "chanserv/gstats", 0, 2) @@ -58,7 +61,8 @@ public: class CSStats; static CSStats *me; -class CSStats : public Module +class CSStats + : public Module { CommandCSStats commandcsstats; CommandCSGStats commandcsgstats; diff --git a/modules/stats/cs_fantasy_top.cpp b/modules/stats/cs_fantasy_top.cpp index ee1e5656f..2c2282648 100644 --- a/modules/stats/cs_fantasy_top.cpp +++ b/modules/stats/cs_fantasy_top.cpp @@ -12,7 +12,8 @@ #include "module.h" #include "modules/sql.h" -class MySQLInterface : public SQL::Interface +class MySQLInterface + : public SQL::Interface { public: MySQLInterface(Module *o) : SQL::Interface(o) { } @@ -30,7 +31,8 @@ public: } }; -class CommandCSTop : public Command +class CommandCSTop + : public Command { public: CommandCSTop(Module *creator) : Command (creator, "chanserv/top", 0, 2) @@ -42,7 +44,8 @@ public: void Execute(CommandSource &source, const std::vector<Anope::string> ¶ms); }; -class CommandCSTop10 : public Command +class CommandCSTop10 + : public Command { public: CommandCSTop10(Module *creator) : Command (creator, "chanserv/top10", 0, 2) @@ -54,7 +57,8 @@ public: void Execute(CommandSource &source, const std::vector<Anope::string> ¶ms); }; -class CommandCSGTop : public Command +class CommandCSGTop + : public Command { public: CommandCSGTop(Module *creator) : Command (creator, "chanserv/gtop", 0, 1) @@ -65,7 +69,8 @@ public: void Execute(CommandSource &source, const std::vector<Anope::string> ¶ms); }; -class CommandCSGTop10 : public Command +class CommandCSGTop10 + : public Command { public: CommandCSGTop10(Module *creator) : Command (creator, "chanserv/gtop10", 0, 1) @@ -79,7 +84,8 @@ public: class CSTop; static CSTop *me; -class CSTop : public Module +class CSTop + : public Module { CommandCSTop commandcstop; CommandCSGTop commandcsgtop; diff --git a/modules/stats/irc2sql/irc2sql.h b/modules/stats/irc2sql/irc2sql.h index c033b2a43..d6944525e 100644 --- a/modules/stats/irc2sql/irc2sql.h +++ b/modules/stats/irc2sql/irc2sql.h @@ -11,7 +11,8 @@ #include "module.h" #include "modules/sql.h" -class MySQLInterface : public SQL::Interface +class MySQLInterface + : public SQL::Interface { public: MySQLInterface(Module *o) : SQL::Interface(o) { } @@ -29,7 +30,8 @@ public: } }; -class IRC2SQL : public Module +class IRC2SQL + : public Module { ServiceReference<SQL::Provider> sql; MySQLInterface sqlinterface; diff --git a/modules/stats/m_chanstats.cpp b/modules/stats/m_chanstats.cpp index e0f72e199..408b1d0a6 100644 --- a/modules/stats/m_chanstats.cpp +++ b/modules/stats/m_chanstats.cpp @@ -9,7 +9,8 @@ #include "module.h" #include "modules/sql.h" -class CommandCSSetChanstats : public Command +class CommandCSSetChanstats + : public Command { public: CommandCSSetChanstats(Module *creator) : Command(creator, "chanserv/set/chanstats", 2, 2) @@ -63,7 +64,8 @@ public: } }; -class CommandNSSetChanstats : public Command +class CommandNSSetChanstats + : public Command { public: CommandNSSetChanstats(Module *creator, const Anope::string &sname = "nickserv/set/chanstats", size_t min = 1 ) : Command(creator, sname, min, min + 1) @@ -121,7 +123,8 @@ public: } }; -class CommandNSSASetChanstats : public CommandNSSetChanstats +class CommandNSSASetChanstats + : public CommandNSSetChanstats { public: CommandNSSASetChanstats(Module *creator) : CommandNSSetChanstats(creator, "nickserv/saset/chanstats", 2) @@ -144,7 +147,8 @@ public: } }; -class MySQLInterface : public SQL::Interface +class MySQLInterface + : public SQL::Interface { public: MySQLInterface(Module *o) : SQL::Interface(o) { } @@ -162,7 +166,8 @@ public: } }; -class MChanstats : public Module +class MChanstats + : public Module { SerializableExtensibleItem<bool> cs_stats, ns_stats; diff --git a/modules/webcpanel/pages/chanserv/access.h b/modules/webcpanel/pages/chanserv/access.h index e386b3d31..bc2a99bd8 100644 --- a/modules/webcpanel/pages/chanserv/access.h +++ b/modules/webcpanel/pages/chanserv/access.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace ChanServ { -class Access : public WebPanelProtectedPage +class Access + : public WebPanelProtectedPage { public: Access(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/chanserv/akick.h b/modules/webcpanel/pages/chanserv/akick.h index 72549e0b7..fe09f8583 100644 --- a/modules/webcpanel/pages/chanserv/akick.h +++ b/modules/webcpanel/pages/chanserv/akick.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace ChanServ { -class Akick : public WebPanelProtectedPage +class Akick + : public WebPanelProtectedPage { public: Akick(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/chanserv/drop.h b/modules/webcpanel/pages/chanserv/drop.h index 849a5e236..7f9e7ecf8 100644 --- a/modules/webcpanel/pages/chanserv/drop.h +++ b/modules/webcpanel/pages/chanserv/drop.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace ChanServ { - class Drop : public WebPanelProtectedPage + class Drop + : public WebPanelProtectedPage { public: Drop(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/chanserv/info.h b/modules/webcpanel/pages/chanserv/info.h index 91c8d2422..e6e5579ef 100644 --- a/modules/webcpanel/pages/chanserv/info.h +++ b/modules/webcpanel/pages/chanserv/info.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace ChanServ { -class Info : public WebPanelProtectedPage +class Info + : public WebPanelProtectedPage { public: Info(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/chanserv/modes.h b/modules/webcpanel/pages/chanserv/modes.h index a6ddce67f..becb1b1d7 100644 --- a/modules/webcpanel/pages/chanserv/modes.h +++ b/modules/webcpanel/pages/chanserv/modes.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace ChanServ { -class Modes : public WebPanelProtectedPage +class Modes + : public WebPanelProtectedPage { public: Modes(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/chanserv/set.h b/modules/webcpanel/pages/chanserv/set.h index 48b11ccf2..0d0f08029 100644 --- a/modules/webcpanel/pages/chanserv/set.h +++ b/modules/webcpanel/pages/chanserv/set.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace ChanServ { -class Set : public WebPanelProtectedPage +class Set + : public WebPanelProtectedPage { public: Set(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/confirm.h b/modules/webcpanel/pages/confirm.h index bb755f9c7..875175571 100644 --- a/modules/webcpanel/pages/confirm.h +++ b/modules/webcpanel/pages/confirm.h @@ -12,7 +12,8 @@ namespace WebCPanel { -class Confirm : public WebPanelPage +class Confirm + : public WebPanelPage { public: Confirm(const Anope::string &u) : WebPanelPage(u) { } diff --git a/modules/webcpanel/pages/hostserv/request.h b/modules/webcpanel/pages/hostserv/request.h index 1df48e40c..dc800a2c8 100644 --- a/modules/webcpanel/pages/hostserv/request.h +++ b/modules/webcpanel/pages/hostserv/request.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace HostServ { -class Request : public WebPanelProtectedPage +class Request + : public WebPanelProtectedPage { public: Request(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/index.cpp b/modules/webcpanel/pages/index.cpp index bb83aba61..e7453d698 100644 --- a/modules/webcpanel/pages/index.cpp +++ b/modules/webcpanel/pages/index.cpp @@ -7,7 +7,8 @@ #include "../webcpanel.h" -class WebpanelRequest : public IdentifyRequest +class WebpanelRequest + : public IdentifyRequest { HTTPReply reply; HTTPMessage message; diff --git a/modules/webcpanel/pages/index.h b/modules/webcpanel/pages/index.h index d28fbf567..d25069f8e 100644 --- a/modules/webcpanel/pages/index.h +++ b/modules/webcpanel/pages/index.h @@ -12,7 +12,8 @@ namespace WebCPanel { -class Index : public WebPanelPage +class Index + : public WebPanelPage { static const int FLUSH_TIME = 60; diff --git a/modules/webcpanel/pages/logout.h b/modules/webcpanel/pages/logout.h index 8f170ea92..94fd60cb5 100644 --- a/modules/webcpanel/pages/logout.h +++ b/modules/webcpanel/pages/logout.h @@ -10,7 +10,8 @@ namespace WebCPanel { -class Logout : public WebPanelProtectedPage +class Logout + : public WebPanelProtectedPage { public: Logout(const Anope::string &u); diff --git a/modules/webcpanel/pages/memoserv/memos.h b/modules/webcpanel/pages/memoserv/memos.h index bb5ebfd6f..bb5cec5fe 100644 --- a/modules/webcpanel/pages/memoserv/memos.h +++ b/modules/webcpanel/pages/memoserv/memos.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace MemoServ { -class Memos : public WebPanelProtectedPage +class Memos + : public WebPanelProtectedPage { public: Memos(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/nickserv/access.h b/modules/webcpanel/pages/nickserv/access.h index 6dc9fe0d6..f0d421bf7 100644 --- a/modules/webcpanel/pages/nickserv/access.h +++ b/modules/webcpanel/pages/nickserv/access.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace NickServ { -class Access : public WebPanelProtectedPage +class Access + : public WebPanelProtectedPage { public: Access(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/nickserv/alist.h b/modules/webcpanel/pages/nickserv/alist.h index 2eddd7699..3dbccbc78 100644 --- a/modules/webcpanel/pages/nickserv/alist.h +++ b/modules/webcpanel/pages/nickserv/alist.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace NickServ { -class Alist : public WebPanelProtectedPage +class Alist + : public WebPanelProtectedPage { public: Alist(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/nickserv/cert.h b/modules/webcpanel/pages/nickserv/cert.h index 2ec3ac029..62f7f0e52 100644 --- a/modules/webcpanel/pages/nickserv/cert.h +++ b/modules/webcpanel/pages/nickserv/cert.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace NickServ { -class Cert : public WebPanelProtectedPage +class Cert + : public WebPanelProtectedPage { public: Cert(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/nickserv/confirm.h b/modules/webcpanel/pages/nickserv/confirm.h index 7b1e4a8b8..e71217b8c 100644 --- a/modules/webcpanel/pages/nickserv/confirm.h +++ b/modules/webcpanel/pages/nickserv/confirm.h @@ -11,7 +11,8 @@ namespace WebCPanel namespace NickServ { -class Confirm : public WebPanelProtectedPage +class Confirm + : public WebPanelProtectedPage { public: Confirm(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/nickserv/info.h b/modules/webcpanel/pages/nickserv/info.h index dd3c2e440..a7b826990 100644 --- a/modules/webcpanel/pages/nickserv/info.h +++ b/modules/webcpanel/pages/nickserv/info.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace NickServ { -class Info : public WebPanelProtectedPage +class Info + : public WebPanelProtectedPage { public: Info(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/operserv/akill.h b/modules/webcpanel/pages/operserv/akill.h index 6eb69b68b..11d95d3fa 100644 --- a/modules/webcpanel/pages/operserv/akill.h +++ b/modules/webcpanel/pages/operserv/akill.h @@ -13,7 +13,8 @@ namespace WebCPanel namespace OperServ { -class Akill : public WebPanelProtectedPage +class Akill + : public WebPanelProtectedPage { public: Akill(const Anope::string &cat, const Anope::string &u); diff --git a/modules/webcpanel/pages/register.h b/modules/webcpanel/pages/register.h index 46e8ec782..e49ab05da 100644 --- a/modules/webcpanel/pages/register.h +++ b/modules/webcpanel/pages/register.h @@ -12,7 +12,8 @@ namespace WebCPanel { -class Register : public WebPanelPage +class Register + : public WebPanelPage { public: Register(const Anope::string &u) : WebPanelPage(u) { } diff --git a/modules/webcpanel/static_fileserver.h b/modules/webcpanel/static_fileserver.h index 6fc2da263..16e1fcd7b 100644 --- a/modules/webcpanel/static_fileserver.h +++ b/modules/webcpanel/static_fileserver.h @@ -10,7 +10,8 @@ #include "modules/httpd.h" /* A basic file server. Used for serving static content on disk. */ -class StaticFileServer : public HTTPPage +class StaticFileServer + : public HTTPPage { Anope::string file_name; public: diff --git a/modules/webcpanel/template_fileserver.h b/modules/webcpanel/template_fileserver.h index 5e224568e..8c5437e30 100644 --- a/modules/webcpanel/template_fileserver.h +++ b/modules/webcpanel/template_fileserver.h @@ -14,7 +14,8 @@ class TemplateFileServer { Anope::string file_name; public: - struct Replacements : std::multimap<Anope::string, Anope::string> + struct Replacements + : std::multimap<Anope::string, Anope::string> { Anope::string& operator[](const Anope::string &key) { diff --git a/modules/webcpanel/webcpanel.cpp b/modules/webcpanel/webcpanel.cpp index 7524dc2ca..910547a27 100644 --- a/modules/webcpanel/webcpanel.cpp +++ b/modules/webcpanel/webcpanel.cpp @@ -10,7 +10,8 @@ Module *me; Anope::string provider_name, template_name, template_base, page_title; -class ModuleWebCPanel : public Module +class ModuleWebCPanel + : public Module { ServiceReference<HTTPProvider> provider; Panel panel; @@ -260,7 +261,8 @@ namespace WebPanel bi = BotListByNick->begin()->second; // Pick one... } - struct MyComandReply : CommandReply + struct MyComandReply + : CommandReply { TemplateFileServer::Replacements &re; const Anope::string &k; @@ -300,7 +302,8 @@ namespace WebPanel if (!info) return; - struct MyComandReply : CommandReply + struct MyComandReply + : CommandReply { TemplateFileServer::Replacements &re; const Anope::string &k; diff --git a/modules/webcpanel/webcpanel.h b/modules/webcpanel/webcpanel.h index 8ec3ea8f9..2501971a8 100644 --- a/modules/webcpanel/webcpanel.h +++ b/modules/webcpanel/webcpanel.h @@ -30,7 +30,9 @@ struct Section }; /* An interface for this webpanel used by other modules */ -class Panel : public Section, public Service +class Panel + : public Section + , public Service { public: Panel(Module *c, const Anope::string &n) : Service(c, "Panel", n) { } @@ -63,7 +65,8 @@ public: } }; -class WebPanelPage : public HTTPPage +class WebPanelPage + : public HTTPPage { public: WebPanelPage(const Anope::string &u, const Anope::string &ct = "text/html") : HTTPPage(u, ct) @@ -73,7 +76,8 @@ public: virtual bool OnRequest(HTTPProvider *, const Anope::string &, HTTPClient *, HTTPMessage &, HTTPReply &) = 0; }; -class WebPanelProtectedPage : public WebPanelPage +class WebPanelProtectedPage + : public WebPanelPage { Anope::string category; diff --git a/src/main.cpp b/src/main.cpp index f2228eead..a9697395b 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -41,7 +41,8 @@ time_t Anope::CurTime = time(NULL); size_t Anope::CurrentUplink = -1; -class UpdateTimer : public Timer +class UpdateTimer + : public Timer { public: UpdateTimer(time_t timeout) : Timer(timeout, Anope::CurTime, true) { } @@ -52,7 +53,8 @@ public: } }; -class ExpireTimer : public Timer +class ExpireTimer + : public Timer { public: ExpireTimer(time_t timeout) : Timer(timeout, Anope::CurTime, true) { } diff --git a/src/modes.cpp b/src/modes.cpp index fa416cba5..0c64589d0 100644 --- a/src/modes.cpp +++ b/src/modes.cpp @@ -300,7 +300,8 @@ void StackerInfo::AddMode(Mode *mode, bool set, const Anope::string ¶m) list->emplace_back(mode, param); } -static class ModePipe : public Pipe +static class ModePipe + : public Pipe { public: void OnNotify() override diff --git a/src/uplink.cpp b/src/uplink.cpp index 170900e30..cc5850ba1 100644 --- a/src/uplink.cpp +++ b/src/uplink.cpp @@ -17,7 +17,8 @@ UplinkSocket *UplinkSock = NULL; -class ReconnectTimer : public Timer +class ReconnectTimer + : public Timer { public: ReconnectTimer(int wait) : Timer(wait) { } |