1
0
mirror of https://github.com/anope/anope.git synced 2026-07-05 01:33:12 +02:00

Replace anope_{final,override} with their C++11 equivalent.

This commit is contained in:
Sadie Powell
2022-01-03 16:50:06 +00:00
parent d76d747196
commit a5f7aac295
202 changed files with 1517 additions and 1528 deletions
+2 -5
View File
@@ -22,13 +22,10 @@ Anope Internal Events
The full list of functions and parameters are in modules.h. In this
case, you would be overriding OnJoinChannel() and OnPartChannel() like so:
void OnJoinChannel(User *u, Channel *c) anope_override { }
void OnPartChannel(User *u, Channel *c) anope_override { }
void OnJoinChannel(User *u, Channel *c) override { }
void OnPartChannel(User *u, Channel *c) override { }
Some of these event overrides can be used to prevent or allow things to
happen that would normally not be allowed or denied. You can also use
ModuleManager (not explained here) to set control which order the modules
are queried (when multiple modules hook to the same event).
The "anope_override" identifier is for compatibility with C++11.
Its usage is highly recommended.
+1 -1
View File
@@ -95,7 +95,7 @@ class CoreExport ChanAccess : public Serializable
const Anope::string &Mask() const;
NickCore *GetAccount() const;
void Serialize(Serialize::Data &data) const anope_override;
void Serialize(Serialize::Data &data) const override;
static Serializable* Unserialize(Serializable *obj, Serialize::Data &);
static const unsigned int MAX_DEPTH = 4;
+2 -2
View File
@@ -54,7 +54,7 @@ class CoreExport NickAlias : public Serializable, public Extensible
NickAlias(const Anope::string &nickname, NickCore *nickcore);
~NickAlias();
void Serialize(Serialize::Data &data) const anope_override;
void Serialize(Serialize::Data &data) const override;
static Serializable* Unserialize(Serializable *obj, Serialize::Data &);
/** Set a vhost for the user
@@ -149,7 +149,7 @@ class CoreExport NickCore : public Serializable, public Extensible
NickCore(const Anope::string &nickdisplay, uint64_t nickid = 0);
~NickCore();
void Serialize(Serialize::Data &data) const anope_override;
void Serialize(Serialize::Data &data) const override;
static Serializable* Unserialize(Serializable *obj, Serialize::Data &);
/** Changes the display for this account
+8 -8
View File
@@ -93,7 +93,7 @@ class BaseExtensibleItem : public ExtensibleBase
return t;
}
void Unset(Extensible *obj) anope_override
void Unset(Extensible *obj) override
{
T *value = Get(obj);
items.erase(obj);
@@ -128,7 +128,7 @@ template<typename T>
class ExtensibleItem : public BaseExtensibleItem<T>
{
protected:
T* Create(Extensible *obj) anope_override
T* Create(Extensible *obj) override
{
return new T(obj);
}
@@ -140,7 +140,7 @@ template<typename T>
class PrimitiveExtensibleItem : public BaseExtensibleItem<T>
{
protected:
T* Create(Extensible *obj) anope_override
T* Create(Extensible *obj) override
{
return new T();
}
@@ -152,7 +152,7 @@ template<>
class PrimitiveExtensibleItem<bool> : public BaseExtensibleItem<bool>
{
protected:
bool* Create(Extensible *) anope_override
bool* Create(Extensible *) override
{
return NULL;
}
@@ -166,13 +166,13 @@ class SerializableExtensibleItem : public PrimitiveExtensibleItem<T>
public:
SerializableExtensibleItem(Module *m, const Anope::string &n) : PrimitiveExtensibleItem<T>(m, n) { }
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const anope_override
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const override
{
T* t = this->Get(e);
data[this->name] << *t;
}
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) anope_override
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) override
{
T t;
if (data[this->name] >> t)
@@ -188,12 +188,12 @@ class SerializableExtensibleItem<bool> : public PrimitiveExtensibleItem<bool>
public:
SerializableExtensibleItem(Module *m, const Anope::string &n) : PrimitiveExtensibleItem<bool>(m, n) { }
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const anope_override
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const override
{
data[this->name] << true;
}
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) anope_override
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) override
{
bool b = false;
data[this->name] >> b;
+4 -4
View File
@@ -38,7 +38,7 @@ namespace Anope
class ascii_ctype : public std::ctype<char_type>
{
public:
char_type do_toupper(char_type c) const anope_override
char_type do_toupper(char_type c) const override
{
if (c >= 'a' && c <= 'z')
return c - 32;
@@ -46,7 +46,7 @@ namespace Anope
return c;
}
char_type do_tolower(char_type c) const anope_override
char_type do_tolower(char_type c) const override
{
if (c >= 'A' && c <= 'Z')
return c + 32;
@@ -60,7 +60,7 @@ namespace Anope
class rfc1459_ctype : public ascii_ctype<char_type>
{
public:
char_type do_toupper(char_type c) const anope_override
char_type do_toupper(char_type c) const override
{
if (c == '{' || c == '}' || c == '|')
return c - 32;
@@ -68,7 +68,7 @@ namespace Anope
return ascii_ctype<char_type>::do_toupper(c);
}
char_type do_tolower(char_type c) const anope_override
char_type do_tolower(char_type c) const override
{
if (c == '[' || c == ']' || c == '\\')
return c + 32;
+1 -1
View File
@@ -48,7 +48,7 @@ namespace Mail
~Message();
/* Called from within the thread to actually send the mail */
void Run() anope_override;
void Run() override;
};
} // namespace Mail
+1 -1
View File
@@ -24,7 +24,7 @@ class CoreExport Memo : public Serializable
Memo();
~Memo();
void Serialize(Serialize::Data &data) const anope_override;
void Serialize(Serialize::Data &data) const override;
static Serializable* Unserialize(Serializable *obj, Serialize::Data &);
Anope::string owner;
+20 -20
View File
@@ -23,35 +23,35 @@ namespace Message
{
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
struct CoreExport Join : IRCDMessage
{
Join(Module *creator, const Anope::string &mname = "JOIN") : IRCDMessage(creator, mname, 1) { SetFlag(IRCDMESSAGE_REQUIRE_USER); SetFlag(IRCDMESSAGE_SOFT_LIMIT); }
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
typedef std::pair<ChannelStatus, User *> SJoinUser;
@@ -69,105 +69,105 @@ namespace Message
{
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
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> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
struct CoreExport Whois : IRCDMessage
{
Whois(Module *creator, const Anope::string &mname = "WHOIS") : IRCDMessage(creator, mname, 1) { SetFlag(IRCDMESSAGE_SOFT_LIMIT); }
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) anope_override;
void Run(MessageSource &source, const std::vector<Anope::string> &params, const Anope::map<Anope::string> &tags) override;
};
} // namespace Message
+9 -9
View File
@@ -105,7 +105,7 @@ class CoreExport ChannelMode : public Mode
*/
ChannelMode(const Anope::string &name, char mc);
bool CanSet(User *u) const anope_override;
bool CanSet(User *u) const override;
virtual void Check() { }
@@ -217,11 +217,11 @@ class CoreExport ChannelModeVirtual : public T
~ChannelModeVirtual();
void Check() anope_override;
void Check() override;
ChannelMode *Wrap(Anope::string &param) anope_override;
ChannelMode *Wrap(Anope::string &param) override;
ChannelMode *Unwrap(ChannelMode *cm, Anope::string &param) anope_override = 0;
ChannelMode *Unwrap(ChannelMode *cm, Anope::string &param) override = 0;
};
/* The status a user has on a channel (+v, +h, +o) etc */
@@ -245,7 +245,7 @@ class CoreExport UserModeOperOnly : public UserMode
public:
UserModeOperOnly(const Anope::string &mname, char um) : UserMode(mname, um) { }
bool CanSet(User *u) const anope_override;
bool CanSet(User *u) const override;
};
class CoreExport UserModeNoone : public UserMode
@@ -253,7 +253,7 @@ class CoreExport UserModeNoone : public UserMode
public:
UserModeNoone(const Anope::string &mname, char um) : UserMode(mname, um) { }
bool CanSet(User *u) const anope_override;
bool CanSet(User *u) const override;
};
/** Channel mode +k (key)
@@ -263,7 +263,7 @@ class CoreExport ChannelModeKey : public ChannelModeParam
public:
ChannelModeKey(char mc) : ChannelModeParam("KEY", mc) { }
bool IsValid(Anope::string &value) const anope_override;
bool IsValid(Anope::string &value) const override;
};
/** This class is used for oper only channel modes
@@ -274,7 +274,7 @@ class CoreExport ChannelModeOperOnly : public ChannelMode
ChannelModeOperOnly(const Anope::string &mname, char mc) : ChannelMode(mname, mc) { }
/* Opers only */
bool CanSet(User *u) const anope_override;
bool CanSet(User *u) const override;
};
/** This class is used for channel modes only servers may set
@@ -284,7 +284,7 @@ class CoreExport ChannelModeNoone : public ChannelMode
public:
ChannelModeNoone(const Anope::string &mname, char mc) : ChannelMode(mname, mc) { }
bool CanSet(User *u) const anope_override;
bool CanSet(User *u) const override;
};
/** This is the mode manager
+1 -1
View File
@@ -164,7 +164,7 @@ namespace DNS
/** Used to time out the query, xalls OnError and lets the TimerManager
* delete this request.
*/
void Tick(time_t) anope_override
void Tick(time_t) override
{
Log(LOG_DEBUG_2) << "Resolver: timeout for query " << this->name;
Query rr(*this);
+1 -1
View File
@@ -28,7 +28,7 @@ struct Exception : Serializable
time_t expires; /* Time when it expires. 0 == no expiry */
Exception() : Serializable("Exception") { }
void Serialize(Serialize::Data &data) const anope_override;
void Serialize(Serialize::Data &data) const override;
static Serializable* Unserialize(Serializable *obj, Serialize::Data &data);
};
+2 -2
View File
@@ -82,7 +82,7 @@ namespace SASL
public:
IdentifyRequest(Module *m, const Anope::string &id, const Anope::string &acc, const Anope::string &pass, const Anope::string &h, const Anope::string &i) : ::IdentifyRequest(m, acc, pass), uid(id), hostname(h), ip(i) { }
void OnSuccess() anope_override
void OnSuccess() override
{
if (!sasl)
return;
@@ -108,7 +108,7 @@ namespace SASL
}
}
void OnFail() anope_override
void OnFail() override
{
if (!sasl)
return;
+5 -5
View File
@@ -21,7 +21,7 @@ namespace SQL
Clear();
}
std::iostream& operator[](const Anope::string &key) anope_override
std::iostream& operator[](const Anope::string &key) override
{
std::stringstream *&ss = data[key];
if (!ss)
@@ -29,7 +29,7 @@ namespace SQL
return *ss;
}
std::set<Anope::string> KeySet() const anope_override
std::set<Anope::string> KeySet() const override
{
std::set<Anope::string> keys;
for (Map::const_iterator it = this->data.begin(), it_end = this->data.end(); it != it_end; ++it)
@@ -37,7 +37,7 @@ namespace SQL
return keys;
}
size_t Hash() const anope_override
size_t Hash() const override
{
size_t hash = 0;
for (Map::const_iterator it = this->data.begin(), it_end = this->data.end(); it != it_end; ++it)
@@ -61,12 +61,12 @@ namespace SQL
this->data.clear();
}
void SetType(const Anope::string &key, Type t) anope_override
void SetType(const Anope::string &key, Type t) override
{
this->types[key] = t;
}
Type GetType(const Anope::string &key) const anope_override
Type GetType(const Anope::string &key) const override
{
std::map<Anope::string, Type>::const_iterator it = this->types.find(key);
if (it != this->types.end())
+2 -2
View File
@@ -38,7 +38,7 @@ class CoreExport AutoKick : public Serializable
AutoKick();
~AutoKick();
void Serialize(Serialize::Data &data) const anope_override;
void Serialize(Serialize::Data &data) const override;
static Serializable* Unserialize(Serializable *obj, Serialize::Data &);
};
@@ -94,7 +94,7 @@ class CoreExport ChannelInfo : public Serializable, public Extensible
~ChannelInfo();
void Serialize(Serialize::Data &data) const anope_override;
void Serialize(Serialize::Data &data) const override;
static Serializable* Unserialize(Serializable *obj, Serialize::Data &);
/** Change the founder of the channel
+1 -1
View File
@@ -134,7 +134,7 @@ class ServiceReference : public Reference<T>
this->invalid = true;
}
operator bool() anope_override
operator bool() override
{
if (this->invalid)
{
-8
View File
@@ -48,14 +48,6 @@
#define _(x) x
#if defined __GXX_EXPERIMENTAL_CXX0X__ || __cplusplus >= 201103L
# define anope_override override
# define anope_final final
#else
# define anope_override
# define anope_final
#endif
#ifndef _WIN32
# define DllExport
# define CoreExport
+9 -9
View File
@@ -291,12 +291,12 @@ class CoreExport BufferedSocket : public virtual Socket
/** Called when there is something to be received for this socket
* @return true on success, false to drop this socket
*/
bool ProcessRead() anope_override;
bool ProcessRead() override;
/** Called when the socket is ready to be written to
* @return true on success, false to drop this socket
*/
bool ProcessWrite() anope_override;
bool ProcessWrite() override;
/** Gets the new line from the input buffer, if any
*/
@@ -345,12 +345,12 @@ class CoreExport BinarySocket : public virtual Socket
/** Called when there is something to be received for this socket
* @return true on success, false to drop this socket
*/
bool ProcessRead() anope_override;
bool ProcessRead() override;
/** Called when the socket is ready to be written to
* @return true on success, false to drop this socket
*/
bool ProcessWrite() anope_override;
bool ProcessWrite() override;
/** Write data to the socket
* @param buffer The data to write
@@ -408,12 +408,12 @@ class CoreExport ConnectionSocket : public virtual Socket
* Used to determine whether or not this socket is connected yet.
* @return true to continue to call ProcessRead/ProcessWrite, false to not continue
*/
bool Process() anope_override;
bool Process() override;
/** Called when there is an error for this socket
* @return true on success, false to drop this socket
*/
void ProcessError() anope_override;
void ProcessError() override;
/** Called on a successful connect
*/
@@ -443,12 +443,12 @@ class CoreExport ClientSocket : public virtual Socket
* Used to determine whether or not this socket is connected yet.
* @return true to continue to call ProcessRead/ProcessWrite, false to not continue
*/
bool Process() anope_override;
bool Process() override;
/** Called when there is an error for this socket
* @return true on success, false to drop this socket
*/
void ProcessError() anope_override;
void ProcessError() override;
/** Called when a client has been accepted() successfully.
*/
@@ -472,7 +472,7 @@ class CoreExport Pipe : public Socket
/** Called when data is to be read, reads the data then calls OnNotify
*/
bool ProcessRead() anope_override;
bool ProcessRead() override;
/** Write data to this pipe
* @param data The data to write
+3 -3
View File
@@ -27,9 +27,9 @@ class UplinkSocket : public ConnectionSocket, public BufferedSocket
bool error;
UplinkSocket();
~UplinkSocket();
bool ProcessRead() anope_override;
void OnConnect() anope_override;
void OnError(const Anope::string &) anope_override;
bool ProcessRead() override;
void OnConnect() override;
void OnError(const Anope::string &) override;
/* A message sent over the uplink socket */
class CoreExport Message
+1 -1
View File
@@ -190,7 +190,7 @@ class CoreExport User : public virtual Base, public Extensible, public CommandRe
* @param ... any number of parameters
*/
void SendMessage(BotInfo *source, const char *fmt, ...);
void SendMessage(BotInfo *source, const Anope::string &msg) anope_override;
void SendMessage(BotInfo *source, const Anope::string &msg) override;
/** Identify the user to a nick.
* updates last_seen, logs the user in,
+1 -1
View File
@@ -44,7 +44,7 @@ class CoreExport XLine : public Serializable
bool HasNickOrReal() const;
bool IsRegex() const;
void Serialize(Serialize::Data &data) const anope_override;
void Serialize(Serialize::Data &data) const override;
static Serializable* Unserialize(Serializable *obj, Serialize::Data &data);
};
+1 -1
View File
@@ -16,7 +16,7 @@ class BSAutoAssign : public Module
{
}
void OnChanRegistered(ChannelInfo *ci) anope_override
void OnChanRegistered(ChannelInfo *ci) override
{
const Anope::string &bot = Config->GetModule(this)->Get<const Anope::string>("bot");
if (bot.empty())
+8 -8
View File
@@ -20,7 +20,7 @@ class CommandBSAssign : public Command
this->SetSyntax(_("\037channel\037 \037nick\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &chan = params[0];
const Anope::string &nick = params[1];
@@ -71,7 +71,7 @@ class CommandBSAssign : public Command
source.Reply(_("Bot \002%s\002 has been assigned to %s."), bi->nick.c_str(), ci->name.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -91,7 +91,7 @@ class CommandBSUnassign : public Command
this->SetSyntax(_("\037channel\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -132,7 +132,7 @@ class CommandBSUnassign : public Command
source.Reply(_("There is no bot assigned to %s anymore."), ci->name.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -154,7 +154,7 @@ class CommandBSSetNoBot : public Command
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci = ChannelInfo::Find(params[0]);
const Anope::string &value = params[1];
@@ -191,7 +191,7 @@ class CommandBSSetNoBot : public Command
this->OnSyntaxError(source, source.command);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(_(" \n"
@@ -217,7 +217,7 @@ class BSAssign : public Module
{
}
void OnInvite(User *source, Channel *c, User *targ) anope_override
void OnInvite(User *source, Channel *c, User *targ) override
{
BotInfo *bi;
if (Anope::ReadOnly || !c->ci || targ->server != Me || !(bi = dynamic_cast<BotInfo *>(targ)))
@@ -246,7 +246,7 @@ class BSAssign : public Module
targ->SendMessage(bi, _("Bot \002%s\002 has been assigned to %s."), bi->nick.c_str(), c->name.c_str());
}
void OnBotInfo(CommandSource &source, BotInfo *bi, ChannelInfo *ci, InfoFormatter &info) anope_override
void OnBotInfo(CommandSource &source, BotInfo *bi, ChannelInfo *ci, InfoFormatter &info) override
{
if (nobot.HasExt(ci))
info.AddOption(_("No bot"));
+11 -11
View File
@@ -17,7 +17,7 @@ struct BadWordImpl : BadWord, Serializable
BadWordImpl() : Serializable("BadWord") { }
~BadWordImpl();
void Serialize(Serialize::Data &data) const anope_override
void Serialize(Serialize::Data &data) const override
{
data["ci"] << this->chan;
data["word"] << this->word;
@@ -37,7 +37,7 @@ struct BadWordsImpl : BadWords
~BadWordsImpl();
BadWord* AddBadWord(const Anope::string &word, BadWordType type) anope_override
BadWord* AddBadWord(const Anope::string &word, BadWordType type) override
{
BadWordImpl *bw = new BadWordImpl();
bw->chan = ci->name;
@@ -51,7 +51,7 @@ struct BadWordsImpl : BadWords
return bw;
}
BadWord* GetBadWord(unsigned index) const anope_override
BadWord* GetBadWord(unsigned index) const override
{
if (this->badwords->empty() || index >= this->badwords->size())
return NULL;
@@ -61,12 +61,12 @@ struct BadWordsImpl : BadWords
return bw;
}
unsigned GetBadWordCount() const anope_override
unsigned GetBadWordCount() const override
{
return this->badwords->size();
}
void EraseBadWord(unsigned index) anope_override
void EraseBadWord(unsigned index) override
{
if (this->badwords->empty() || index >= this->badwords->size())
return;
@@ -76,13 +76,13 @@ struct BadWordsImpl : BadWords
delete this->badwords->at(index);
}
void ClearBadWords() anope_override
void ClearBadWords() override
{
while (!this->badwords->empty())
delete this->badwords->back();
}
void Check() anope_override
void Check() override
{
if (this->badwords->empty())
ci->Shrink<BadWords>("badwords");
@@ -170,7 +170,7 @@ class BadwordsDelCallback : public NumberList
source.Reply(_("Deleted %d entries from %s bad words list."), deleted, ci->name.c_str());
}
void HandleNumber(unsigned Number) anope_override
void HandleNumber(unsigned Number) override
{
if (!bw || !Number || Number > bw->GetBadWordCount())
return;
@@ -209,7 +209,7 @@ class CommandBSBadwords : public Command
{
}
void HandleNumber(unsigned Number) anope_override
void HandleNumber(unsigned Number) override
{
if (!Number || Number > bw->GetBadWordCount())
return;
@@ -374,7 +374,7 @@ class CommandBSBadwords : public Command
this->SetSyntax(_("\037channel\037 CLEAR"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &cmd = params[1];
const Anope::string &word = params.size() > 2 ? params[2] : "";
@@ -417,7 +417,7 @@ class CommandBSBadwords : public Command
this->OnSyntaxError(source, "");
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -272,7 +272,7 @@ class CommandBSBot : public Command
this->SetSyntax(_("\002DEL \037nick\037\002"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &cmd = params[0];
@@ -345,7 +345,7 @@ class CommandBSBot : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -19,7 +19,7 @@ class CommandBSBotList : public Command
this->SetDesc(_("Lists available bots"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
unsigned count = 0;
ListFormatter list(source.GetAccount());
@@ -57,7 +57,7 @@ class CommandBSBotList : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+4 -4
View File
@@ -20,7 +20,7 @@ class CommandBSSay : public Command
this->SetSyntax(_("\037channel\037 \037text\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &text = params[1];
@@ -62,7 +62,7 @@ class CommandBSSay : public Command
Log(override ? LOG_OVERRIDE : LOG_COMMAND, source, this, ci) << "to say: " << text;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -80,7 +80,7 @@ class CommandBSAct : public Command
this->SetSyntax(_("\037channel\037 \037text\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
Anope::string message = params[1];
@@ -120,7 +120,7 @@ class CommandBSAct : public Command
Log(override ? LOG_OVERRIDE : LOG_COMMAND, source, this, ci) << "to say: " << message;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+3 -3
View File
@@ -41,7 +41,7 @@ class CommandBSInfo : public Command
this->SetSyntax(_("{\037channel\037 | \037nickname\037}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &query = params[0];
@@ -101,7 +101,7 @@ class CommandBSInfo : public Command
source.Reply(_("\002%s\002 is not a valid bot or registered channel."), query.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -113,7 +113,7 @@ class CommandBSInfo : public Command
return true;
}
const Anope::string GetDesc(CommandSource &source) const anope_override
const Anope::string GetDesc(CommandSource &source) const override
{
return Anope::printf(Language::Translate(source.GetAccount(), _("Allows you to see %s information about a channel or a bot")), source.service->nick.c_str());
}
+34 -34
View File
@@ -29,7 +29,7 @@ struct KickerDataImpl : KickerData
dontkickops = dontkickvoices = false;
}
void Check(ChannelInfo *ci) anope_override
void Check(ChannelInfo *ci) override
{
if (amsgs || badwords || bolds || caps || colors || flood || italics || repeat || reverses || underlines)
return;
@@ -41,7 +41,7 @@ struct KickerDataImpl : KickerData
{
ExtensibleItem(Module *m, const Anope::string &ename) : ::ExtensibleItem<KickerDataImpl>(m, ename) { }
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const anope_override
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const override
{
if (s->GetSerializableType()->GetName() != "ChannelInfo")
return;
@@ -71,7 +71,7 @@ struct KickerDataImpl : KickerData
data["ttb"] << kd->ttb[i] << " ";
}
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) anope_override
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) override
{
if (s->GetSerializableType()->GetName() != "ChannelInfo")
return;
@@ -120,12 +120,12 @@ class CommandBSKick : public Command
this->SetSyntax(_("\037option\037 \037channel\037 {\037ON|OFF\037} [\037settings\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->OnSyntaxError(source, "");
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -165,9 +165,9 @@ class CommandBSKickBase : public Command
{
}
virtual void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override = 0;
virtual void Execute(CommandSource &source, const std::vector<Anope::string> &params) override = 0;
virtual bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override = 0;
virtual bool OnHelp(CommandSource &source, const Anope::string &subcommand) override = 0;
protected:
bool CheckArguments(CommandSource &source, const std::vector<Anope::string> &params, ChannelInfo* &ci)
@@ -252,7 +252,7 @@ class CommandBSKickAMSG : public CommandBSKickBase
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037} [\037ttb\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci;
if (CheckArguments(source, params, ci))
@@ -263,7 +263,7 @@ class CommandBSKickAMSG : public CommandBSKickBase
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -288,7 +288,7 @@ class CommandBSKickBadwords : public CommandBSKickBase
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037} [\037ttb\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci;
if (CheckArguments(source, params, ci))
@@ -300,7 +300,7 @@ class CommandBSKickBadwords : public CommandBSKickBase
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -327,7 +327,7 @@ class CommandBSKickBolds : public CommandBSKickBase
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037} [\037ttb\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci;
if (CheckArguments(source, params, ci))
@@ -338,7 +338,7 @@ class CommandBSKickBolds : public CommandBSKickBase
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -361,7 +361,7 @@ class CommandBSKickCaps : public CommandBSKickBase
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037} [\037ttb\037 [\037min\037 [\037percent\037]]]\002"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci;
if (!CheckArguments(source, params, ci))
@@ -429,7 +429,7 @@ class CommandBSKickCaps : public CommandBSKickBase
kd->Check(ci);
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -457,7 +457,7 @@ class CommandBSKickColors : public CommandBSKickBase
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037} [\037ttb\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci;
if (CheckArguments(source, params, ci))
@@ -468,7 +468,7 @@ class CommandBSKickColors : public CommandBSKickBase
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -491,7 +491,7 @@ class CommandBSKickFlood : public CommandBSKickBase
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037} [\037ttb\037 [\037ln\037 [\037secs\037]]]\002"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci;
if (!CheckArguments(source, params, ci))
@@ -564,7 +564,7 @@ class CommandBSKickFlood : public CommandBSKickBase
kd->Check(ci);
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -589,7 +589,7 @@ class CommandBSKickItalics : public CommandBSKickBase
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037} [\037ttb\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci;
if (CheckArguments(source, params, ci))
@@ -600,7 +600,7 @@ class CommandBSKickItalics : public CommandBSKickBase
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -623,7 +623,7 @@ class CommandBSKickRepeat : public CommandBSKickBase
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037} [\037ttb\037 [\037num\037]]\002"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci;
if (!CheckArguments(source, params, ci))
@@ -699,7 +699,7 @@ class CommandBSKickRepeat : public CommandBSKickBase
kd->Check(ci);
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -724,7 +724,7 @@ class CommandBSKickReverses : public CommandBSKickBase
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037} [\037ttb\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci;
if (CheckArguments(source, params, ci))
@@ -735,7 +735,7 @@ class CommandBSKickReverses : public CommandBSKickBase
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -758,7 +758,7 @@ class CommandBSKickUnderlines : public CommandBSKickBase
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037} [\037ttb\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci;
if (CheckArguments(source, params, ci))
@@ -769,7 +769,7 @@ class CommandBSKickUnderlines : public CommandBSKickBase
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -792,7 +792,7 @@ class CommandBSSetDontKickOps : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci = ChannelInfo::Find(params[0]);
if (ci == NULL)
@@ -837,7 +837,7 @@ class CommandBSSetDontKickOps : public Command
kd->Check(ci);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(_(" \n"
@@ -857,7 +857,7 @@ class CommandBSSetDontKickVoices : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci = ChannelInfo::Find(params[0]);
if (ci == NULL)
@@ -902,7 +902,7 @@ class CommandBSSetDontKickVoices : public Command
kd->Check(ci);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(_(" \n"
@@ -989,7 +989,7 @@ class BanDataPurger : public Timer
public:
BanDataPurger(Module *o) : Timer(o, 300, Anope::CurTime, true) { }
void Tick(time_t) anope_override
void Tick(time_t) override
{
Log(LOG_DEBUG) << "bs_main: Running bandata purger";
@@ -1106,7 +1106,7 @@ class BSKick : public Module
}
void OnBotInfo(CommandSource &source, BotInfo *bi, ChannelInfo *ci, InfoFormatter &info) anope_override
void OnBotInfo(CommandSource &source, BotInfo *bi, ChannelInfo *ci, InfoFormatter &info) override
{
if (!ci)
return;
@@ -1221,7 +1221,7 @@ class BSKick : public Module
info.AddOption(_("Voices protection"));
}
void OnPrivmsg(User *u, Channel *c, Anope::string &msg) anope_override
void OnPrivmsg(User *u, Channel *c, Anope::string &msg) override
{
/* Now we can make kicker stuff. We try to order the checks
* from the fastest one to the slowest one, since there's
+8 -8
View File
@@ -20,12 +20,12 @@ class CommandBSSet : public Command
this->SetSyntax(_("\037option\037 \037(channel | bot)\037 \037settings\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->OnSyntaxError(source, "");
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -77,7 +77,7 @@ class CommandBSSetBanExpire : public Command
public:
UnbanTimer(Module *creator, const Anope::string &ch, const Anope::string &bmask, time_t t) : Timer(creator, t), chname(ch), mask(bmask) { }
void Tick(time_t) anope_override
void Tick(time_t) override
{
Channel *c = Channel::Find(chname);
if (c)
@@ -91,7 +91,7 @@ class CommandBSSetBanExpire : public Command
this->SetSyntax(_("\037channel\037 \037time\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &chan = params[0];
const Anope::string &arg = params[1];
@@ -141,7 +141,7 @@ class CommandBSSetBanExpire : public Command
source.Reply(_("Bot bans will automatically expire after %s."), Anope::Duration(ci->banexpire, source.GetAccount()).c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(_(" \n"
@@ -162,7 +162,7 @@ class CommandBSSetPrivate : public Command
this->SetSyntax(_("\037botname\037 {\037ON|OFF\037}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
BotInfo *bi = BotInfo::Find(params[0], true);
const Anope::string &value = params[1];
@@ -193,7 +193,7 @@ class CommandBSSetPrivate : public Command
this->OnSyntaxError(source, source.command);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(_(" \n"
@@ -216,7 +216,7 @@ class BSSet : public Module
{
}
void OnBotBan(User *u, ChannelInfo *ci, const Anope::string &mask) anope_override
void OnBotBan(User *u, ChannelInfo *ci, const Anope::string &mask) override
{
if (!ci->banexpire)
return;
+15 -15
View File
@@ -29,17 +29,17 @@ class AccessChanAccess : public ChanAccess
{
}
bool HasPriv(const Anope::string &name) const anope_override
bool HasPriv(const Anope::string &name) const override
{
return this->ci->GetLevel(name) != ACCESS_INVALID && this->level >= this->ci->GetLevel(name);
}
Anope::string AccessSerialize() const anope_override
Anope::string AccessSerialize() const override
{
return stringify(this->level);
}
void AccessUnserialize(const Anope::string &data) anope_override
void AccessUnserialize(const Anope::string &data) override
{
try
{
@@ -50,7 +50,7 @@ class AccessChanAccess : public ChanAccess
}
}
bool operator>(const ChanAccess &other) const anope_override
bool operator>(const ChanAccess &other) const override
{
if (this->provider != other.provider)
return ChanAccess::operator>(other);
@@ -58,7 +58,7 @@ class AccessChanAccess : public ChanAccess
return this->level > anope_dynamic_static_cast<const AccessChanAccess *>(&other)->level;
}
bool operator<(const ChanAccess &other) const anope_override
bool operator<(const ChanAccess &other) const override
{
if (this->provider != other.provider)
return ChanAccess::operator<(other);
@@ -77,7 +77,7 @@ class AccessAccessProvider : public AccessProvider
me = this;
}
ChanAccess *Create() anope_override
ChanAccess *Create() override
{
return new AccessChanAccess(this);
}
@@ -278,7 +278,7 @@ class CommandCSAccess : public Command
}
}
void HandleNumber(unsigned Number) anope_override
void HandleNumber(unsigned Number) override
{
if (!Number || Number > ci->GetAccessCount())
return;
@@ -359,7 +359,7 @@ class CommandCSAccess : public Command
{
}
void HandleNumber(unsigned number) anope_override
void HandleNumber(unsigned number) override
{
if (!number || number > ci->GetAccessCount())
return;
@@ -503,7 +503,7 @@ class CommandCSAccess : public Command
this->SetSyntax(_("\037channel\037 CLEAR"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &cmd = params[1];
const Anope::string &nick = params.size() > 2 ? params[2] : "";
@@ -561,7 +561,7 @@ class CommandCSAccess : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -745,7 +745,7 @@ class CommandCSLevels : public Command
this->SetSyntax(_("\037channel\037 RESET"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &cmd = params[1];
const Anope::string &what = params.size() > 2 ? params[2] : "";
@@ -789,7 +789,7 @@ class CommandCSLevels : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
if (subcommand.equals_ci("DESC"))
{
@@ -856,7 +856,7 @@ class CSAccess : public Module
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
defaultLevels.clear();
@@ -882,12 +882,12 @@ class CSAccess : public Module
}
}
void OnCreateChan(ChannelInfo *ci) anope_override
void OnCreateChan(ChannelInfo *ci) override
{
reset_levels(ci);
}
EventReturn OnGroupCheckPriv(const AccessGroup *group, const Anope::string &priv) anope_override
EventReturn OnGroupCheckPriv(const AccessGroup *group, const Anope::string &priv) override
{
if (group->ci == NULL)
return EVENT_CONTINUE;
+5 -5
View File
@@ -228,7 +228,7 @@ class CommandCSAKick : public Command
source.Reply(_("Deleted %d entries from %s autokick list."), deleted, ci->name.c_str());
}
void HandleNumber(unsigned number) anope_override
void HandleNumber(unsigned number) override
{
if (!number || number > ci->GetAkickCount())
return;
@@ -293,7 +293,7 @@ class CommandCSAKick : public Command
{
}
void HandleNumber(unsigned number) anope_override
void HandleNumber(unsigned number) override
{
if (!number || number > ci->GetAkickCount())
return;
@@ -440,7 +440,7 @@ class CommandCSAKick : public Command
this->SetSyntax(_("\037channel\037 CLEAR"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
Anope::string chan = params[0];
Anope::string cmd = params[1];
@@ -485,7 +485,7 @@ class CommandCSAKick : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
BotInfo *bi = Config->GetClient("NickServ");
this->SendSyntax(source);
@@ -538,7 +538,7 @@ class CSAKick : public Module
{
}
EventReturn OnCheckKick(User *u, Channel *c, Anope::string &mask, Anope::string &reason) anope_override
EventReturn OnCheckKick(User *u, Channel *c, Anope::string &mask, Anope::string &reason) override
{
if (!c->ci || c->MatchesList(u, "EXCEPT"))
return EVENT_CONTINUE;
+3 -3
View File
@@ -23,7 +23,7 @@ class TempBan : public Timer
public:
TempBan(time_t seconds, Channel *c, const Anope::string &banmask, const Anope::string &mod) : Timer(me, seconds), channel(c->name), mask(banmask), mode(mod) { }
void Tick(time_t ctime) anope_override
void Tick(time_t ctime) override
{
Channel *c = Channel::Find(this->channel);
if (c)
@@ -40,7 +40,7 @@ class CommandCSBan : public Command
this->SetSyntax(_("\037channel\037 [+\037expiry\037] {\037nick\037 | \037mask\037} [\037reason\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
Configuration::Block *block = Config->GetCommand(source);
const Anope::string &mode = block->Get<Anope::string>("mode", "BAN");
@@ -223,7 +223,7 @@ class CommandCSBan : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -115,7 +115,7 @@ public:
this->SetSyntax(_("\037channel\037 \037target\037 [\037what\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &channel = params[0];
const Anope::string &target = params[1];
@@ -235,7 +235,7 @@ public:
Log(override ? LOG_OVERRIDE : LOG_COMMAND, source, this, ci) << "to clone " << (what.empty() ? "everything from it" : what) << " to " << target_ci->name;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandCSDrop : public Command
this->SetSyntax(_("\037channel\037 \037channel\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &chan = params[0];
@@ -66,7 +66,7 @@ class CommandCSDrop : public Command
c->CheckModes();
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -228,7 +228,7 @@ class CommandCSEnforce : public Command
this->SetSyntax(_("\037channel\037 \037what\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &what = params.size() > 1 ? params[1] : "";
@@ -256,7 +256,7 @@ class CommandCSEnforce : public Command
this->OnSyntaxError(source, "");
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+5 -5
View File
@@ -28,7 +28,7 @@ struct EntryMsgImpl : EntryMsg, Serializable
~EntryMsgImpl();
void Serialize(Serialize::Data &data) const anope_override
void Serialize(Serialize::Data &data) const override
{
data["ci"] << this->chan;
data["creator"] << this->creator;
@@ -43,7 +43,7 @@ struct EntryMessageListImpl : EntryMessageList
{
EntryMessageListImpl(Extensible *) { }
EntryMsg* Create() anope_override
EntryMsg* Create() override
{
return new EntryMsgImpl();
}
@@ -197,7 +197,7 @@ class CommandEntryMessage : public Command
this->SetSyntax(_("\037channel\037 CLEAR"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci = ChannelInfo::Find(params[0]);
if (ci == NULL)
@@ -232,7 +232,7 @@ class CommandEntryMessage : public Command
this->OnSyntaxError(source, "");
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -273,7 +273,7 @@ class CSEntryMessage : public Module
{
}
void OnJoinChannel(User *u, Channel *c) anope_override
void OnJoinChannel(User *u, Channel *c) override
{
if (u && c && c->ci && u->server->IsSynced())
{
+7 -7
View File
@@ -22,7 +22,7 @@ class FlagsChanAccess : public ChanAccess
{
}
bool HasPriv(const Anope::string &priv) const anope_override
bool HasPriv(const Anope::string &priv) const override
{
std::map<Anope::string, char>::iterator it = defaultFlags.find(priv);
if (it != defaultFlags.end() && this->flags.count(it->second) > 0)
@@ -30,12 +30,12 @@ class FlagsChanAccess : public ChanAccess
return false;
}
Anope::string AccessSerialize() const anope_override
Anope::string AccessSerialize() const override
{
return Anope::string(this->flags.begin(), this->flags.end());
}
void AccessUnserialize(const Anope::string &data) anope_override
void AccessUnserialize(const Anope::string &data) override
{
for (unsigned i = data.length(); i > 0; --i)
this->flags.insert(data[i - 1]);
@@ -69,7 +69,7 @@ class FlagsAccessProvider : public AccessProvider
ap = this;
}
ChanAccess *Create() anope_override
ChanAccess *Create() override
{
return new FlagsChanAccess(this);
}
@@ -376,7 +376,7 @@ class CommandCSFlags : public Command
this->SetSyntax(_("\037channel\037 CLEAR"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &chan = params[0];
const Anope::string &cmd = params.size() > 1 ? params[1] : "";
@@ -425,7 +425,7 @@ class CommandCSFlags : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -478,7 +478,7 @@ class CSFlags : public Module
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
defaultFlags.clear();
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandCSGetKey : public Command
this->SetSyntax(_("\037channel\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &chan = params[0];
@@ -50,7 +50,7 @@ class CommandCSGetKey : public Command
source.Reply(_("Key for channel \002%s\002 is \002%s\002."), chan.c_str(), key.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -21,7 +21,7 @@ class CommandCSInfo : public Command
this->AllowUnregistered(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &chan = params[0];
@@ -69,7 +69,7 @@ class CommandCSInfo : public Command
source.Reply(replies[i]);
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandCSInvite : public Command
this->SetSyntax(_("\037channel\037 [\037nick\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &chan = params[0];
@@ -84,7 +84,7 @@ class CommandCSInvite : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -21,7 +21,7 @@ class CommandCSKick : public Command
this->SetSyntax(_("\037channel\037 \037mask\037 [\037reason\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &chan = params[0];
const Anope::string &target = params[1];
@@ -121,7 +121,7 @@ class CommandCSKick : public Command
source.Reply(NICK_X_NOT_IN_USE, target.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+5 -5
View File
@@ -21,7 +21,7 @@ class CommandCSList : public Command
this->SetSyntax(_("\037pattern\037 [SUSPENDED] [NOEXPIRE]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
Anope::string pattern = params[0];
unsigned nchans;
@@ -130,7 +130,7 @@ class CommandCSList : public Command
source.Reply(_("End of list - %d/%d matches shown."), nchans > listmax ? listmax : nchans, nchans);
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -181,7 +181,7 @@ class CommandCSSetPrivate : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -225,7 +225,7 @@ class CommandCSSetPrivate : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -253,7 +253,7 @@ class CSList : public Module
{
}
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool show_all) anope_override
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool show_all) override
{
if (!show_all)
return;
+7 -7
View File
@@ -33,7 +33,7 @@ struct LogSettingImpl : LogSetting, Serializable
}
}
void Serialize(Serialize::Data &data) const anope_override
void Serialize(Serialize::Data &data) const override
{
data["ci"] << chan;
data["service_name"] << service_name;
@@ -91,7 +91,7 @@ struct LogSettingsImpl : LogSettings
}
}
LogSetting *Create() anope_override
LogSetting *Create() override
{
return new LogSettingImpl();
}
@@ -107,7 +107,7 @@ public:
this->SetSyntax(_("\037channel\037 \037command\037 \037method\037 [\037status\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &channel = params[0];
@@ -251,7 +251,7 @@ public:
this->OnSyntaxError(source, "");
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -301,7 +301,7 @@ class CSLog : public Module
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
Configuration::Block *block = conf->GetModule(this);
defaults.clear();
@@ -320,7 +320,7 @@ class CSLog : public Module
}
}
void OnChanRegistered(ChannelInfo *ci) anope_override
void OnChanRegistered(ChannelInfo *ci) override
{
if (defaults.empty())
return;
@@ -353,7 +353,7 @@ class CSLog : public Module
}
}
void OnLog(Log *l) anope_override
void OnLog(Log *l) override
{
if (l->type != LOG_COMMAND || l->u == NULL || l->c == NULL || l->ci == NULL || !Me || !Me->IsSynced())
return;
+20 -20
View File
@@ -29,7 +29,7 @@ struct ModeLockImpl : ModeLock, Serializable
}
}
void Serialize(Serialize::Data &data) const anope_override;
void Serialize(Serialize::Data &data) const override;
static Serializable* Unserialize(Serializable *obj, Serialize::Data &data);
};
@@ -53,7 +53,7 @@ struct ModeLocksImpl : ModeLocks
}
}
bool HasMLock(ChannelMode *mode, const Anope::string &param, bool status) const anope_override
bool HasMLock(ChannelMode *mode, const Anope::string &param, bool status) const override
{
if (!mode)
return false;
@@ -69,7 +69,7 @@ struct ModeLocksImpl : ModeLocks
return false;
}
bool SetMLock(ChannelMode *mode, bool status, const Anope::string &param, Anope::string setter, time_t created = Anope::CurTime) anope_override
bool SetMLock(ChannelMode *mode, bool status, const Anope::string &param, Anope::string setter, time_t created = Anope::CurTime) override
{
if (!mode)
return false;
@@ -99,7 +99,7 @@ struct ModeLocksImpl : ModeLocks
return true;
}
bool RemoveMLock(ChannelMode *mode, bool status, const Anope::string &param = "") anope_override
bool RemoveMLock(ChannelMode *mode, bool status, const Anope::string &param = "") override
{
if (!mode)
return false;
@@ -128,14 +128,14 @@ struct ModeLocksImpl : ModeLocks
return false;
}
void RemoveMLock(ModeLock *mlock) anope_override
void RemoveMLock(ModeLock *mlock) override
{
ModeList::iterator it = std::find(this->mlocks->begin(), this->mlocks->end(), mlock);
if (it != this->mlocks->end())
this->mlocks->erase(it);
}
void ClearMLock() anope_override
void ClearMLock() override
{
ModeList ml;
this->mlocks->swap(ml);
@@ -143,12 +143,12 @@ struct ModeLocksImpl : ModeLocks
delete ml[i];
}
const ModeList &GetMLock() const anope_override
const ModeList &GetMLock() const override
{
return this->mlocks;
}
std::list<ModeLock *> GetModeLockList(const Anope::string &name) anope_override
std::list<ModeLock *> GetModeLockList(const Anope::string &name) override
{
std::list<ModeLock *> mlist;
for (ModeList::const_iterator it = this->mlocks->begin(); it != this->mlocks->end(); ++it)
@@ -160,7 +160,7 @@ struct ModeLocksImpl : ModeLocks
return mlist;
}
const ModeLock *GetMLock(const Anope::string &mname, const Anope::string &param = "") anope_override
const ModeLock *GetMLock(const Anope::string &mname, const Anope::string &param = "") override
{
for (ModeList::const_iterator it = this->mlocks->begin(); it != this->mlocks->end(); ++it)
{
@@ -173,7 +173,7 @@ struct ModeLocksImpl : ModeLocks
return NULL;
}
Anope::string GetMLockAsString(bool complete) const anope_override
Anope::string GetMLockAsString(bool complete) const override
{
Anope::string pos = "+", neg = "-", params;
@@ -202,7 +202,7 @@ struct ModeLocksImpl : ModeLocks
return pos + neg + params;
}
void Check() anope_override
void Check() override
{
if (this->mlocks->empty())
ci->Shrink<ModeLocks>("modelocks");
@@ -736,7 +736,7 @@ class CommandCSMode : public Command
this->SetSyntax(_("\037channel\037 CLEAR [\037what\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &subcommand = params[1];
@@ -766,7 +766,7 @@ class CommandCSMode : public Command
this->OnSyntaxError(source, "");
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -807,7 +807,7 @@ class CommandCSModes : public Command
this->SetSyntax(_("\037channel\037 [\037user\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
User *u = source.GetUser(),
*targ = params.size() > 1 ? User::Find(params[1], true) : u;
@@ -879,7 +879,7 @@ class CommandCSModes : public Command
Log(override ? LOG_OVERRIDE : LOG_COMMAND, source, this, ci) << "on " << targ->nick;
}
const Anope::string GetDesc(CommandSource &source) const anope_override
const Anope::string GetDesc(CommandSource &source) const override
{
const std::pair<bool, Anope::string> &m = modes[source.command];
if (!m.second.empty())
@@ -893,7 +893,7 @@ class CommandCSModes : public Command
return "";
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
const std::pair<bool, Anope::string> &m = modes[source.command];
if (m.second.empty())
@@ -932,7 +932,7 @@ class CSMode : public Module
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
modes.clear();
@@ -956,7 +956,7 @@ class CSMode : public Module
}
}
void OnCheckModes(Reference<Channel> &c) anope_override
void OnCheckModes(Reference<Channel> &c) override
{
if (!c || !c->ci)
return;
@@ -1005,7 +1005,7 @@ class CSMode : public Module
}
}
void OnChanRegistered(ChannelInfo *ci) anope_override
void OnChanRegistered(ChannelInfo *ci) override
{
ModeLocks *ml = modelocks.Require(ci);
Anope::string mlock;
@@ -1055,7 +1055,7 @@ class CSMode : public Module
ml->Check();
}
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool show_hidden) anope_override
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool show_hidden) override
{
if (!show_hidden)
return;
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandCSRegister : public Command
this->SetSyntax(_("\037channel\037 [\037description\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &chan = params[0];
const Anope::string &chdesc = params.size() > 1 ? params[1] : "";
@@ -79,7 +79,7 @@ class CommandCSRegister : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+13 -13
View File
@@ -43,7 +43,7 @@ struct SeenInfo : Serializable
database.erase(iter);
}
void Serialize(Serialize::Data &data) const anope_override
void Serialize(Serialize::Data &data) const override
{
data["nick"] << nick;
data["vhost"] << vhost;
@@ -119,7 +119,7 @@ class CommandOSSeen : public Command
this->SetSyntax(_("CLEAR \037time\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (params[0].equals_ci("STATS"))
{
@@ -165,7 +165,7 @@ class CommandOSSeen : public Command
this->SendSyntax(source);
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -263,7 +263,7 @@ class CommandSeen : public Command
this->AllowUnregistered(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &target = params[0];
@@ -360,7 +360,7 @@ class CommandSeen : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -381,12 +381,12 @@ class CSSeen : public Module
{
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
simple = conf->GetModule(this)->Get<bool>("simple");
}
void OnExpireTick() anope_override
void OnExpireTick() override
{
size_t previous_size = database.size();
time_t purgetime = Config->GetModule(this)->Get<time_t>("purgetime");
@@ -406,34 +406,34 @@ class CSSeen : public Module
Log(LOG_DEBUG) << "cs_seen: Purged database, checked " << previous_size << " nicks and removed " << (previous_size - database.size()) << " old entries.";
}
void OnUserConnect(User *u, bool &exempt) anope_override
void OnUserConnect(User *u, bool &exempt) override
{
if (!u->Quitting())
UpdateUser(u, NEW, u->nick, "", "", "");
}
void OnUserNickChange(User *u, const Anope::string &oldnick) anope_override
void OnUserNickChange(User *u, const Anope::string &oldnick) override
{
UpdateUser(u, NICK_TO, oldnick, u->nick, "", "");
UpdateUser(u, NICK_FROM, u->nick, oldnick, "", "");
}
void OnUserQuit(User *u, const Anope::string &msg) anope_override
void OnUserQuit(User *u, const Anope::string &msg) override
{
UpdateUser(u, QUIT, u->nick, "", "", msg);
}
void OnJoinChannel(User *u, Channel *c) anope_override
void OnJoinChannel(User *u, Channel *c) override
{
UpdateUser(u, JOIN, u->nick, "", c->name, "");
}
void OnPartChannel(User *u, Channel *c, const Anope::string &channel, const Anope::string &msg) anope_override
void OnPartChannel(User *u, Channel *c, const Anope::string &channel, const Anope::string &msg) override
{
UpdateUser(u, PART, u->nick, "", channel, msg);
}
void OnPreUserKicked(const MessageSource &source, ChanUserContainer *cu, const Anope::string &msg) anope_override
void OnPreUserKicked(const MessageSource &source, ChanUserContainer *cu, const Anope::string &msg) override
{
UpdateUser(cu->user, KICK, cu->user->nick, source.GetSource(), cu->chan->name, msg);
}
+43 -43
View File
@@ -21,12 +21,12 @@ class CommandCSSet : public Command
this->SetSyntax(_("\037option\037 \037channel\037 \037parameters\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->OnSyntaxError(source, "");
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -75,7 +75,7 @@ class CommandCSSetAutoOp : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -117,7 +117,7 @@ class CommandCSSetAutoOp : public Command
this->OnSyntaxError(source, "AUTOOP");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -138,7 +138,7 @@ class CommandCSSetBanType : public Command
this->SetSyntax(_("\037channel\037 \037bantype\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -179,7 +179,7 @@ class CommandCSSetBanType : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -205,7 +205,7 @@ class CommandCSSetDescription : public Command
this->SetSyntax(_("\037channel\037 [\037description\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -248,7 +248,7 @@ class CommandCSSetDescription : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -267,7 +267,7 @@ class CommandCSSetFounder : public Command
this->SetSyntax(_("\037channel\037 \037nick\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -317,7 +317,7 @@ class CommandCSSetFounder : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -336,7 +336,7 @@ class CommandCSSetKeepModes : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -381,7 +381,7 @@ class CommandCSSetKeepModes : public Command
this->OnSyntaxError(source, "KEEPMODES");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -401,7 +401,7 @@ class CommandCSSetPeace : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -445,7 +445,7 @@ class CommandCSSetPeace : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -473,7 +473,7 @@ class CommandCSSetPersist : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -583,7 +583,7 @@ class CommandCSSetPersist : public Command
this->OnSyntaxError(source, "PERSIST");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
BotInfo *BotServ = Config->GetClient("BotServ");
BotInfo *ChanServ = Config->GetClient("ChanServ");
@@ -622,7 +622,7 @@ class CommandCSSetRestricted : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -664,7 +664,7 @@ class CommandCSSetRestricted : public Command
this->OnSyntaxError(source, "RESTRICTED");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -684,7 +684,7 @@ class CommandCSSetSecure : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -726,7 +726,7 @@ class CommandCSSetSecure : public Command
this->OnSyntaxError(source, "SECURE");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -747,7 +747,7 @@ class CommandCSSetSecureFounder : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -789,7 +789,7 @@ class CommandCSSetSecureFounder : public Command
this->OnSyntaxError(source, "SECUREFOUNDER");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -811,7 +811,7 @@ class CommandCSSetSecureOps : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -853,7 +853,7 @@ class CommandCSSetSecureOps : public Command
this->OnSyntaxError(source, "SECUREOPS");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -873,7 +873,7 @@ class CommandCSSetSignKick : public Command
this->SetSyntax(_("\037channel\037 {ON | LEVEL | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -925,7 +925,7 @@ class CommandCSSetSignKick : public Command
this->OnSyntaxError(source, "SIGNKICK");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -950,7 +950,7 @@ class CommandCSSetSuccessor : public Command
this->SetSyntax(_("\037channel\037 [\037nick\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -1010,7 +1010,7 @@ class CommandCSSetSuccessor : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -1044,7 +1044,7 @@ class CommandCSSetNoexpire : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -1083,7 +1083,7 @@ class CommandCSSetNoexpire : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -1103,7 +1103,7 @@ class CSSet : public Module
{
KeepModes(Module *m, const Anope::string &n) : SerializableExtensibleItem<bool>(m, n) { }
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const anope_override
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const override
{
SerializableExtensibleItem<bool>::ExtensibleSerialize(e, s, data);
@@ -1123,7 +1123,7 @@ class CSSet : public Module
data["last_modes"] << modes;
}
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) anope_override
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) override
{
SerializableExtensibleItem<bool>::ExtensibleUnserialize(e, s, data);
@@ -1184,17 +1184,17 @@ class CSSet : public Module
{
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
persist_lower_ts = conf->GetModule(this)->Get<bool>("persist_lower_ts");
}
void OnCreateChan(ChannelInfo *ci) anope_override
void OnCreateChan(ChannelInfo *ci) override
{
ci->bantype = Config->GetModule(this)->Get<int>("defbantype", "2");
}
void OnChannelSync(Channel *c) anope_override
void OnChannelSync(Channel *c) override
{
if (c->ci && keep_modes.HasExt(c->ci))
{
@@ -1204,7 +1204,7 @@ class CSSet : public Module
}
}
EventReturn OnCheckKick(User *u, Channel *c, Anope::string &mask, Anope::string &reason) anope_override
EventReturn OnCheckKick(User *u, Channel *c, Anope::string &mask, Anope::string &reason) override
{
if (!c->ci || !restricted.HasExt(c->ci) || c->MatchesList(u, "EXCEPT"))
return EVENT_CONTINUE;
@@ -1215,14 +1215,14 @@ class CSSet : public Module
return EVENT_CONTINUE;
}
void OnDelChan(ChannelInfo *ci) anope_override
void OnDelChan(ChannelInfo *ci) override
{
if (ci->c && persist.HasExt(ci))
ci->c->RemoveMode(ci->WhoSends(), "PERM", "", false);
persist.Unset(ci);
}
EventReturn OnChannelModeSet(Channel *c, MessageSource &setter, ChannelMode *mode, const Anope::string &param) anope_override
EventReturn OnChannelModeSet(Channel *c, MessageSource &setter, ChannelMode *mode, const Anope::string &param) override
{
if (c->ci)
{
@@ -1237,7 +1237,7 @@ class CSSet : public Module
return EVENT_CONTINUE;
}
EventReturn OnChannelModeUnset(Channel *c, MessageSource &setter, ChannelMode *mode, const Anope::string &param) anope_override
EventReturn OnChannelModeUnset(Channel *c, MessageSource &setter, ChannelMode *mode, const Anope::string &param) override
{
if (mode->name == "PERM")
{
@@ -1251,7 +1251,7 @@ class CSSet : public Module
return EVENT_CONTINUE;
}
void OnJoinChannel(User *u, Channel *c) anope_override
void OnJoinChannel(User *u, Channel *c) override
{
if (u->server != Me && persist_lower_ts && c->ci && persist.HasExt(c->ci) && c->creation_time > c->ci->time_registered)
{
@@ -1262,7 +1262,7 @@ class CSSet : public Module
}
}
void OnSetCorrectModes(User *user, Channel *chan, AccessGroup &access, bool &give_modes, bool &take_modes) anope_override
void OnSetCorrectModes(User *user, Channel *chan, AccessGroup &access, bool &give_modes, bool &take_modes) override
{
if (chan->ci)
{
@@ -1274,13 +1274,13 @@ class CSSet : public Module
}
}
void OnPreChanExpire(ChannelInfo *ci, bool &expire) anope_override
void OnPreChanExpire(ChannelInfo *ci, bool &expire) override
{
if (noexpire.HasExt(ci))
expire = false;
}
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool show_all) anope_override
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool show_all) override
{
if (!show_all)
return;
+6 -6
View File
@@ -42,7 +42,7 @@ struct CSMiscData : MiscData, Serializable
data = d;
}
void Serialize(Serialize::Data &sdata) const anope_override
void Serialize(Serialize::Data &sdata) const override
{
sdata["ci"] << this->object;
sdata["name"] << this->name;
@@ -96,7 +96,7 @@ class CommandCSSetMisc : public Command
this->SetSyntax(_("\037channel\037 [\037parameters\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -143,7 +143,7 @@ class CommandCSSetMisc : public Command
}
}
void OnServHelp(CommandSource &source) anope_override
void OnServHelp(CommandSource &source) override
{
if (descriptions.count(source.command))
{
@@ -152,7 +152,7 @@ class CommandCSSetMisc : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
if (descriptions.count(source.command))
{
@@ -182,7 +182,7 @@ class CSSetMisc : public Module
delete it->second;
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
descriptions.clear();
@@ -203,7 +203,7 @@ class CSSetMisc : public Module
}
}
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool) anope_override
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool) override
{
for (Anope::map<ExtensibleItem<CSMiscData> *>::iterator it = items.begin(); it != items.end(); ++it)
{
+2 -2
View File
@@ -20,7 +20,7 @@ public:
this->SetSyntax(_("\037channel\037 [\037user\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &channel = params[0];
@@ -99,7 +99,7 @@ public:
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+9 -9
View File
@@ -16,7 +16,7 @@ struct CSSuspendInfo : SuspendInfo, Serializable
{
CSSuspendInfo(Extensible *) : Serializable("CSSuspendInfo") { }
void Serialize(Serialize::Data &data) const anope_override
void Serialize(Serialize::Data &data) const override
{
data["chan"] << what;
data["by"] << by;
@@ -59,7 +59,7 @@ class CommandCSSuspend : public Command
this->SetSyntax(_("\037channel\037 [+\037expiry\037] [\037reason\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &chan = params[0];
Anope::string expiry = params[1];
@@ -127,7 +127,7 @@ class CommandCSSuspend : public Command
FOREACH_MOD(OnChanSuspend, (ci));
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -152,7 +152,7 @@ class CommandCSUnSuspend : public Command
this->SetSyntax(_("\037channel\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
@@ -184,7 +184,7 @@ class CommandCSUnSuspend : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -222,7 +222,7 @@ class CSSuspend : public Module
{
}
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool show_hidden) anope_override
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool show_hidden) override
{
CSSuspendInfo *si = suspend.Get(ci);
if (!si)
@@ -240,7 +240,7 @@ class CSSuspend : public Module
info[_("Suspension expires")] = Anope::strftime(si->expires, source.GetAccount());
}
void OnPreChanExpire(ChannelInfo *ci, bool &expire) anope_override
void OnPreChanExpire(ChannelInfo *ci, bool &expire) override
{
CSSuspendInfo *si = suspend.Get(ci);
if (!si)
@@ -260,7 +260,7 @@ class CSSuspend : public Module
}
}
EventReturn OnCheckKick(User *u, Channel *c, Anope::string &mask, Anope::string &reason) anope_override
EventReturn OnCheckKick(User *u, Channel *c, Anope::string &mask, Anope::string &reason) override
{
if (u->HasMode("OPER") || !c->ci || !suspend.HasExt(c->ci))
return EVENT_CONTINUE;
@@ -269,7 +269,7 @@ class CSSuspend : public Module
return EVENT_STOP;
}
EventReturn OnChanDrop(CommandSource &source, ChannelInfo *ci) anope_override
EventReturn OnChanDrop(CommandSource &source, ChannelInfo *ci) override
{
CSSuspendInfo *si = suspend.Get(ci);
if (si && !source.HasCommand("chanserv/drop"))
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandCSSync : public Command
this->SetSyntax(_("\037channel\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci = ChannelInfo::Find(params[0]);
@@ -42,7 +42,7 @@ class CommandCSSync : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &params) anope_override
bool OnHelp(CommandSource &source, const Anope::string &params) override
{
this->SendSyntax(source);
source.Reply(" ");
+7 -7
View File
@@ -21,7 +21,7 @@ class CommandCSSetKeepTopic : public Command
this->SetSyntax(_("\037channel\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -63,7 +63,7 @@ class CommandCSSetKeepTopic : public Command
this->OnSyntaxError(source, "KEEPTOPIC");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -152,7 +152,7 @@ class CommandCSTopic : public Command
this->SetSyntax(_("\037channel\037 [UNLOCK|LOCK]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &subcmd = params[1];
@@ -186,7 +186,7 @@ class CommandCSTopic : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -216,7 +216,7 @@ class CSTopic : public Module
}
void OnChannelSync(Channel *c) anope_override
void OnChannelSync(Channel *c) override
{
if (c->ci)
{
@@ -228,7 +228,7 @@ class CSTopic : public Module
}
}
void OnTopicUpdated(User *source, Channel *c, const Anope::string &user, const Anope::string &topic) anope_override
void OnTopicUpdated(User *source, Channel *c, const Anope::string &user, const Anope::string &topic) override
{
if (!c->ci)
return;
@@ -250,7 +250,7 @@ class CSTopic : public Module
}
}
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool show_all) anope_override
void OnChanInfo(CommandSource &source, ChannelInfo *ci, InfoFormatter &info, bool show_all) override
{
if (keeptopic.HasExt(ci))
info.AddOption(_("Topic retention"));
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandCSUnban : public Command
this->SetSyntax(_("\037channel\037 [\037nick\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelMode *cm = ModeManager::FindChannelModeByName("BAN");
if (!cm)
@@ -96,7 +96,7 @@ class CommandCSUnban : public Command
source.Reply(_("\002%s\002 has been unbanned from \002%s\002."), u2->nick.c_str(), ci->c->name.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+4 -4
View File
@@ -49,7 +49,7 @@ class CommandCSUp : public Command
this->SetSyntax(_("[\037channel\037 [\037nick\037]]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (params.empty())
{
@@ -119,7 +119,7 @@ class CommandCSUp : public Command
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -147,7 +147,7 @@ class CommandCSDown : public Command
this->SetSyntax(_("[\037channel\037 [\037nick\037]]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (params.empty())
{
@@ -216,7 +216,7 @@ class CommandCSDown : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+10 -10
View File
@@ -26,7 +26,7 @@ class XOPChanAccess : public ChanAccess
{
}
bool HasPriv(const Anope::string &priv) const anope_override
bool HasPriv(const Anope::string &priv) const override
{
for (std::vector<Anope::string>::iterator it = std::find(order.begin(), order.end(), this->type); it != order.end(); ++it)
{
@@ -37,12 +37,12 @@ class XOPChanAccess : public ChanAccess
return false;
}
Anope::string AccessSerialize() const anope_override
Anope::string AccessSerialize() const override
{
return this->type;
}
void AccessUnserialize(const Anope::string &data) anope_override
void AccessUnserialize(const Anope::string &data) override
{
this->type = data;
}
@@ -88,7 +88,7 @@ class XOPAccessProvider : public AccessProvider
{
}
ChanAccess *Create() anope_override
ChanAccess *Create() override
{
return new XOPChanAccess(this);
}
@@ -303,7 +303,7 @@ class CommandCSXOP : public Command
}
}
void HandleNumber(unsigned number) anope_override
void HandleNumber(unsigned number) override
{
if (!number || number > ci->GetAccessCount())
return;
@@ -388,7 +388,7 @@ class CommandCSXOP : public Command
{
}
void HandleNumber(unsigned Number) anope_override
void HandleNumber(unsigned Number) override
{
if (!Number || Number > ci->GetAccessCount())
return;
@@ -484,12 +484,12 @@ class CommandCSXOP : public Command
this->SetSyntax(_("\037channel\037 CLEAR"));
}
const Anope::string GetDesc(CommandSource &source) const anope_override
const Anope::string GetDesc(CommandSource &source) const override
{
return Anope::printf(Language::Translate(source.GetAccount(), _("Modify the list of %s users")), source.command.upper().c_str());
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci = ChannelInfo::Find(params[0]);
if (ci == NULL)
@@ -513,7 +513,7 @@ class CommandCSXOP : public Command
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
const Anope::string &cmd = source.command.upper();
@@ -590,7 +590,7 @@ class CSXOP : public Module
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
order.clear();
permissions.clear();
+2 -2
View File
@@ -22,7 +22,7 @@ class CommandGLGlobal : public Command
this->SetSyntax(_("\037message\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &msg = params[0];
@@ -35,7 +35,7 @@ class CommandGLGlobal : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
Reference<BotInfo> sender;
if (GService)
+9 -9
View File
@@ -20,7 +20,7 @@ class CommandBSSetGreet : public Command
this->SetSyntax(_("\037channel\037 {\037ON|OFF\037}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
ChannelInfo *ci = ChannelInfo::Find(params[0]);
const Anope::string &value = params[1];
@@ -63,7 +63,7 @@ class CommandBSSetGreet : public Command
this->OnSyntaxError(source, source.command);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(_(" \n"
@@ -119,12 +119,12 @@ class CommandNSSetGreet : public Command
}
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, source.nc->display, params.size() > 0 ? params[0] : "");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -145,12 +145,12 @@ class CommandNSSASetGreet : public CommandNSSetGreet
this->SetSyntax(_("\037nickname\037 \037message\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, params[0], params.size() > 1 ? params[1] : "");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -182,7 +182,7 @@ class Greet : public Module
{
}
void OnJoinChannel(User *user, Channel *c) anope_override
void OnJoinChannel(User *user, Channel *c) override
{
/* Only display the greet if the main uplink we're connected
* to has synced, or we'll get greet-floods when the net
@@ -199,14 +199,14 @@ class Greet : public Module
}
}
void OnNickInfo(CommandSource &source, NickAlias *na, InfoFormatter &info, bool show_hidden) anope_override
void OnNickInfo(CommandSource &source, NickAlias *na, InfoFormatter &info, bool show_hidden) override
{
Anope::string *greet = ns_greet.Get(na->nc);
if (greet != NULL)
info[_("Greet")] = *greet;
}
void OnBotInfo(CommandSource &source, BotInfo *bi, ChannelInfo *ci, InfoFormatter &info) anope_override
void OnBotInfo(CommandSource &source, BotInfo *bi, ChannelInfo *ci, InfoFormatter &info) override
{
if (bs_greet.HasExt(ci))
info.AddOption(_("Greet"));
+1 -1
View File
@@ -34,7 +34,7 @@ class CommandHelp : public Command
this->AllowUnregistered(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
EventReturn MOD_RESULT;
FOREACH_RESULT(OnPreHelp, MOD_RESULT, (source, params));
+4 -4
View File
@@ -20,7 +20,7 @@ class CommandHSDel : public Command
this->SetSyntax(_("\037nick\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -41,7 +41,7 @@ class CommandHSDel : public Command
source.Reply(NICK_X_NOT_REGISTERED, nick.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -60,7 +60,7 @@ class CommandHSDelAll : public Command
this->SetSyntax(_("\037nick\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -86,7 +86,7 @@ class CommandHSDelAll : public Command
source.Reply(NICK_X_NOT_REGISTERED, nick.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+5 -5
View File
@@ -42,7 +42,7 @@ class CommandHSGroup : public Command
this->SetDesc(_("Syncs the vhost for all nicks in a group"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -65,7 +65,7 @@ class CommandHSGroup : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -90,7 +90,7 @@ class HSGroup : public Module
throw ModuleException("Your IRCd does not support vhosts");
}
void OnSetVhost(NickAlias *na) anope_override
void OnSetVhost(NickAlias *na) override
{
if (!synconset)
return;
@@ -98,7 +98,7 @@ class HSGroup : public Module
commandhsgroup.Sync(na);
}
void OnNickGroup(User *u, NickAlias *na) anope_override
void OnNickGroup(User *u, NickAlias *na) override
{
if (!syncongroup)
return;
@@ -106,7 +106,7 @@ class HSGroup : public Module
commandhsgroup.Sync(na);
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
Configuration::Block *block = conf->GetModule(this);
syncongroup = block->Get<bool>("syncongroup");
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandHSList : public Command
this->SetSyntax(_("[\037key\037|\037#X-Y\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &key = !params.empty() ? params[0] : "";
int from = 0, to = 0, counter = 1;
@@ -129,7 +129,7 @@ class CommandHSList : public Command
source.Reply(replies[i]);
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandHSOff : public Command
this->RequireUser(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
User *u = source.GetUser();
@@ -42,7 +42,7 @@ class CommandHSOff : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandHSOn : public Command
this->RequireUser(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (!IRCD->CanSetVHost)
return; // HostServ wouldn't even be loaded at this point
@@ -48,7 +48,7 @@ class CommandHSOn : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+9 -9
View File
@@ -29,7 +29,7 @@ struct HostRequest : Serializable
HostRequest(Extensible *) : Serializable("HostRequest") { }
void Serialize(Serialize::Data &data) const anope_override
void Serialize(Serialize::Data &data) const override
{
data["nick"] << this->nick;
data["ident"] << this->ident;
@@ -79,7 +79,7 @@ class CommandHSRequest : public Command
this->SetSyntax(_("vhost"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -172,7 +172,7 @@ class CommandHSRequest : public Command
Log(LOG_COMMAND, source, this) << "to request new vhost " << (!user.empty() ? user + "@" : "") << host;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -192,7 +192,7 @@ class CommandHSActivate : public Command
this->SetSyntax(_("\037nick\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -220,7 +220,7 @@ class CommandHSActivate : public Command
source.Reply(_("No request for nick %s found."), nick.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -241,7 +241,7 @@ class CommandHSReject : public Command
this->SetSyntax(_("\037nick\037 [\037reason\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -276,7 +276,7 @@ class CommandHSReject : public Command
source.Reply(_("No request for nick %s found."), nick.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -296,7 +296,7 @@ class CommandHSWaiting : public Command
this->SetDesc(_("Retrieves the vhost requests"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
unsigned counter = 0;
unsigned display_counter = 0, listmax = Config->GetModule(this->owner)->Get<unsigned>("listmax");
@@ -337,7 +337,7 @@ class CommandHSWaiting : public Command
source.Reply(_("Displayed \002%d\002 records (\002%d\002 total)."), display_counter, counter);
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+4 -4
View File
@@ -20,7 +20,7 @@ class CommandHSSet : public Command
this->SetSyntax(_("\037nick\037 \037hostmask\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -92,7 +92,7 @@ class CommandHSSet : public Command
source.Reply(_("VHost for \002%s\002 set to \002%s\002."), nick.c_str(), host.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -126,7 +126,7 @@ class CommandHSSetAll : public Command
this->SetSyntax(_("\037nick\037 \037hostmask\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -199,7 +199,7 @@ class CommandHSSetAll : public Command
source.Reply(_("VHost for group \002%s\002 set to \002%s\002."), nick.c_str(), host.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandMSCancel : public Command
this->SetSyntax(_("{\037nick\037 | \037channel\037}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -77,7 +77,7 @@ class CommandMSCancel : public Command
source.Reply(_("No memo was cancelable."));
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandMSCheck : public Command
this->SetSyntax(_("\037nick\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &recipient = params[0];
@@ -62,7 +62,7 @@ class CommandMSCheck : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+3 -3
View File
@@ -22,7 +22,7 @@ class MemoDelCallback : public NumberList
{
}
void HandleNumber(unsigned number) anope_override
void HandleNumber(unsigned number) override
{
if (!number || number > mi->memos->size())
return;
@@ -45,7 +45,7 @@ class CommandMSDel : public Command
this->SetSyntax(_("[\037channel\037] {\037num\037 | \037list\037 | LAST | ALL}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -122,7 +122,7 @@ class CommandMSDel : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -22,7 +22,7 @@ class CommandMSIgnore : public Command
this->SetSyntax(_("[\037channel\037] LIST"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -106,7 +106,7 @@ class CommandMSIgnore : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandMSInfo : public Command
this->SetSyntax(_("[\037nick\037 | \037channel\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
NickCore *nc = source.nc;
const MemoInfo *mi;
@@ -197,7 +197,7 @@ class CommandMSInfo : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+3 -3
View File
@@ -20,7 +20,7 @@ class CommandMSList : public Command
this->SetSyntax(_("[\037channel\037] [\037list\037 | NEW]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
Anope::string param = !params.empty() ? params[0] : "", chan;
@@ -75,7 +75,7 @@ class CommandMSList : public Command
{
}
void HandleNumber(unsigned number) anope_override
void HandleNumber(unsigned number) override
{
if (!number || number > mi->memos->size())
return;
@@ -135,7 +135,7 @@ class CommandMSList : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+3 -3
View File
@@ -65,7 +65,7 @@ class MemoListCallback : public NumberList
source.Reply(_("No memos to display."));
}
void HandleNumber(unsigned number) anope_override
void HandleNumber(unsigned number) override
{
if (!number || number > mi->memos->size())
return;
@@ -113,7 +113,7 @@ class CommandMSRead : public Command
this->SetSyntax(_("[\037channel\037] {\037num\037 | \037list\037 | LAST | NEW | ALL}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
MemoInfo *mi;
@@ -192,7 +192,7 @@ class CommandMSRead : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -25,7 +25,7 @@ class CommandMSRSend : public Command
this->SetSyntax(_("{\037nick\037 | \037channel\037} \037memo-text\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (!memoserv)
return;
@@ -73,7 +73,7 @@ class CommandMSRSend : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -25,7 +25,7 @@ class CommandMSSend : public Command
this->SetSyntax(_("{\037nick\037 | \037channel\037} \037memo-text\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (!memoserv)
return;
@@ -59,7 +59,7 @@ class CommandMSSend : public Command
source.Reply(_("Sorry, %s currently has too many memos and cannot receive more."), nick.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -25,7 +25,7 @@ class CommandMSSendAll : public Command
this->SetSyntax(_("\037memo-text\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (!memoserv)
return;
@@ -45,7 +45,7 @@ class CommandMSSendAll : public Command
source.Reply(_("A massmemo has been sent to all registered users."));
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -207,7 +207,7 @@ class CommandMSSet : public Command
this->SetSyntax(_("\037option\037 \037parameters\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &cmd = params[0];
MemoInfo *mi = &source.nc->memos;
@@ -226,7 +226,7 @@ class CommandMSSet : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
if (subcommand.empty())
{
+2 -2
View File
@@ -25,7 +25,7 @@ class CommandMSStaff : public Command
this->SetSyntax(_("\037memo-text\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (!memoserv)
return;
@@ -41,7 +41,7 @@ class CommandMSStaff : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+3 -3
View File
@@ -104,7 +104,7 @@ class CommandNSAccess : public Command
this->SetSyntax(_("LIST [\037nickname\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &cmd = params[0];
Anope::string nick, mask;
@@ -159,7 +159,7 @@ class CommandNSAccess : public Command
this->OnSyntaxError(source, "");
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -196,7 +196,7 @@ class NSAccess : public Module
{
}
void OnNickRegister(User *u, NickAlias *na, const Anope::string &) anope_override
void OnNickRegister(User *u, NickAlias *na, const Anope::string &) override
{
if (u && Config->GetModule(this)->Get<bool>("addaccessonreg"))
na->nc->AddAccess(u->Mask());
+4 -4
View File
@@ -38,7 +38,7 @@ struct AJoinEntry : Serializable
}
}
void Serialize(Serialize::Data &sd) const anope_override
void Serialize(Serialize::Data &sd) const override
{
if (!this->owner)
return;
@@ -233,7 +233,7 @@ class CommandNSAJoin : public Command
this->SetSyntax(_("LIST [\037nickname\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &cmd = params[0];
Anope::string nick, param, param2;
@@ -285,7 +285,7 @@ class CommandNSAJoin : public Command
this->OnSyntaxError(source, "");
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -314,7 +314,7 @@ class NSAJoin : public Module
}
void OnUserLogin(User *u) anope_override
void OnUserLogin(User *u) override
{
BotInfo *NickServ = Config->GetClient("NickServ");
if (!NickServ)
+2 -2
View File
@@ -25,7 +25,7 @@ class CommandNSAList : public Command
this->SetSyntax(_("[\037nickname\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
Anope::string nick = source.GetNick();
NickCore *nc = source.nc;
@@ -120,7 +120,7 @@ class CommandNSAList : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+14 -14
View File
@@ -18,7 +18,7 @@ struct CertServiceImpl : CertService
{
CertServiceImpl(Module *o) : CertService(o) { }
NickCore* FindAccountFromCert(const Anope::string &cert) anope_override
NickCore* FindAccountFromCert(const Anope::string &cert) override
{
Anope::hash_map<NickCore *>::iterator it = certmap.find(cert);
if (it != certmap.end())
@@ -46,7 +46,7 @@ struct NSCertListImpl : NSCertList
*
* Adds a new entry into the cert list.
*/
void AddCert(const Anope::string &entry) anope_override
void AddCert(const Anope::string &entry) override
{
this->certs.push_back(entry);
certmap[entry] = nc;
@@ -60,14 +60,14 @@ struct NSCertListImpl : NSCertList
*
* Retrieves an entry from the certificate list corresponding to the given index.
*/
Anope::string GetCert(unsigned entry) const anope_override
Anope::string GetCert(unsigned entry) const override
{
if (entry >= this->certs.size())
return "";
return this->certs[entry];
}
unsigned GetCertCount() const anope_override
unsigned GetCertCount() const override
{
return this->certs.size();
}
@@ -79,7 +79,7 @@ struct NSCertListImpl : NSCertList
*
* Search for an fingerprint within the cert list.
*/
bool FindCert(const Anope::string &entry) const anope_override
bool FindCert(const Anope::string &entry) const override
{
return std::find(this->certs.begin(), this->certs.end(), entry) != this->certs.end();
}
@@ -90,7 +90,7 @@ struct NSCertListImpl : NSCertList
*
* Removes the specified fingerprint from the cert list.
*/
void EraseCert(const Anope::string &entry) anope_override
void EraseCert(const Anope::string &entry) override
{
std::vector<Anope::string>::iterator it = std::find(this->certs.begin(), this->certs.end(), entry);
if (it != this->certs.end())
@@ -105,7 +105,7 @@ struct NSCertListImpl : NSCertList
*
* Deletes all the memory allocated in the certificate list vector and then clears the vector.
*/
void ClearCert() anope_override
void ClearCert() override
{
FOREACH_MOD(OnNickClearCert, (this->nc));
for (unsigned i = 0; i < certs.size(); ++i)
@@ -113,7 +113,7 @@ struct NSCertListImpl : NSCertList
this->certs.clear();
}
void Check() anope_override
void Check() override
{
if (this->certs.empty())
nc->Shrink<NSCertList>("certificates");
@@ -123,7 +123,7 @@ struct NSCertListImpl : NSCertList
{
ExtensibleItem(Module *m, const Anope::string &ename) : ::ExtensibleItem<NSCertListImpl>(m, ename) { }
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const anope_override
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const override
{
if (s->GetSerializableType()->GetName() != "NickCore")
return;
@@ -137,7 +137,7 @@ struct NSCertListImpl : NSCertList
data["cert"] << c->GetCert(i) << " ";
}
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) anope_override
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) override
{
if (s->GetSerializableType()->GetName() != "NickCore")
return;
@@ -260,7 +260,7 @@ class CommandNSCert : public Command
this->SetSyntax(_("LIST [\037nickname\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &cmd = params[0];
Anope::string nick, certfp;
@@ -312,7 +312,7 @@ class CommandNSCert : public Command
this->OnSyntaxError(source, "");
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -352,7 +352,7 @@ class NSCert : public Module
throw ModuleException("Your IRCd does not support ssl client certificates");
}
void OnFingerprint(User *u) anope_override
void OnFingerprint(User *u) override
{
BotInfo *NickServ = Config->GetClient("NickServ");
if (!NickServ || u->IsIdentified())
@@ -379,7 +379,7 @@ class NSCert : public Module
Log(NickServ) << u->GetMask() << " automatically identified for account " << nc->display << " via SSL certificate fingerprint";
}
EventReturn OnNickValidate(User *u, NickAlias *na) anope_override
EventReturn OnNickValidate(User *u, NickAlias *na) override
{
NSCertList *cl = certs.Get(na->nc);
if (!u->fingerprint.empty() && cl && cl->FindCert(u->fingerprint))
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandNSDrop : public Command
this->SetDesc(_("Cancel the registration of a nickname"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &nick = params[0];
@@ -54,7 +54,7 @@ class CommandNSDrop : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -24,7 +24,7 @@ class CommandNSGetEMail : public Command
this->SetSyntax(_("\037email\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &email = params[0];
int j = 0;
@@ -51,7 +51,7 @@ class CommandNSGetEMail : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+8 -8
View File
@@ -22,7 +22,7 @@ class NSGroupRequest : public IdentifyRequest
public:
NSGroupRequest(Module *o, CommandSource &src, Command *c, const Anope::string &n, NickAlias *targ, const Anope::string &pass) : IdentifyRequest(o, targ->nc->display, pass), source(src), cmd(c), nick(n), target(targ) { }
void OnSuccess() anope_override
void OnSuccess() override
{
User *u = source.GetUser();
@@ -67,7 +67,7 @@ class NSGroupRequest : public IdentifyRequest
u->lastnickreg = Anope::CurTime;
}
void OnFail() anope_override
void OnFail() override
{
User *u = source.GetUser();
@@ -93,7 +93,7 @@ class CommandNSGroup : public Command
this->AllowUnregistered(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
User *user = source.GetUser();
@@ -194,7 +194,7 @@ class CommandNSGroup : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -237,7 +237,7 @@ class CommandNSUngroup : public Command
this->SetSyntax(_("[\037nick\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
Anope::string nick = !params.empty() ? params[0] : "";
NickAlias *na = NickAlias::Find(!nick.empty() ? nick : source.GetNick());
@@ -278,7 +278,7 @@ class CommandNSUngroup : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -299,7 +299,7 @@ class CommandNSGList : public Command
this->SetDesc(_("Lists all nicknames in your group"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &nick = !params.empty() ? params[0] : "";
const NickCore *nc;
@@ -357,7 +357,7 @@ class CommandNSGList : public Command
source.Reply(_("%d nickname(s) in the group."), nc->aliases->size());
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
if (source.IsServicesOper())
source.Reply(_("Syntax: \002%s [\037nickname\037]\002\n"
+4 -4
View File
@@ -19,7 +19,7 @@ class NSIdentifyRequest : public IdentifyRequest
public:
NSIdentifyRequest(Module *o, CommandSource &s, Command *c, const Anope::string &acc, const Anope::string &pass) : IdentifyRequest(o, acc, pass), source(s), cmd(c) { }
void OnSuccess() anope_override
void OnSuccess() override
{
if (!source.GetUser())
return;
@@ -40,7 +40,7 @@ class NSIdentifyRequest : public IdentifyRequest
}
}
void OnFail() anope_override
void OnFail() override
{
if (source.GetUser())
{
@@ -68,7 +68,7 @@ class CommandNSIdentify : public Command
this->RequireUser(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
User *u = source.GetUser();
@@ -100,7 +100,7 @@ class CommandNSIdentify : public Command
req->Dispatch();
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+6 -6
View File
@@ -21,7 +21,7 @@ class CommandNSInfo : public Command
this->AllowUnregistered(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &nick = params.size() ? params[0] : (source.nc ? source.nc->display : source.GetNick());
@@ -119,7 +119,7 @@ class CommandNSInfo : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -212,12 +212,12 @@ class CommandNSSetHide : public Command
this->OnSyntaxError(source, "HIDE");
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, source.nc->display, params[0], params[1]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -240,13 +240,13 @@ class CommandNSSASetHide : public CommandNSSetHide
this->SetSyntax(_("\037nickname\037 {EMAIL | STATUS | USERMASK | QUIT} {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->ClearSyntax();
this->Run(source, params[0], params[1], params[2]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
+7 -7
View File
@@ -20,7 +20,7 @@ class CommandNSList : public Command
this->SetSyntax(_("\037pattern\037 [SUSPENDED] [NOEXPIRE] [UNCONFIRMED]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
Anope::string pattern = params[0];
@@ -132,7 +132,7 @@ class CommandNSList : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -224,12 +224,12 @@ class CommandNSSetPrivate : public Command
this->OnSyntaxError(source, "PRIVATE");
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, source.nc->display, params[0]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -252,12 +252,12 @@ class CommandNSSASetPrivate : public CommandNSSetPrivate
this->SetSyntax(_("\037nickname\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, params[0], params[1]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -288,7 +288,7 @@ class NSList : public Module
{
}
void OnNickInfo(CommandSource &source, NickAlias *na, InfoFormatter &info, bool show_all) anope_override
void OnNickInfo(CommandSource &source, NickAlias *na, InfoFormatter &info, bool show_all) override
{
if (!show_all)
return;
+2 -2
View File
@@ -22,7 +22,7 @@ class CommandNSLogout : public Command
this->SetSyntax(_("[\037nickname\037 [REVALIDATE]]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &nick = !params.empty() ? params[0] : "";
@@ -59,7 +59,7 @@ class CommandNSLogout : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+6 -6
View File
@@ -32,7 +32,7 @@ class NSRecoverRequest : public IdentifyRequest
public:
NSRecoverRequest(Module *o, CommandSource &src, Command *c, const Anope::string &nick, const Anope::string &pass) : IdentifyRequest(o, nick, pass), source(src), cmd(c), user(nick) { }
void OnSuccess() anope_override
void OnSuccess() override
{
User *u = User::Find(user, true);
if (!source.GetUser() || !source.service)
@@ -124,7 +124,7 @@ class NSRecoverRequest : public IdentifyRequest
}
}
void OnFail() anope_override
void OnFail() override
{
if (NickAlias::Find(GetAccount()) != NULL)
{
@@ -151,7 +151,7 @@ class CommandNSRecover : public Command
this->AllowUnregistered(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &nick = params[0];
const Anope::string &pass = params.size() > 1 ? params[1] : "";
@@ -207,7 +207,7 @@ class CommandNSRecover : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -237,7 +237,7 @@ class NSRecover : public Module
}
void OnUserNickChange(User *u, const Anope::string &oldnick) anope_override
void OnUserNickChange(User *u, const Anope::string &oldnick) override
{
if (Config->GetModule(this)->Get<bool>("restoreonrecover"))
{
@@ -272,7 +272,7 @@ class NSRecover : public Module
}
}
void OnJoinChannel(User *u, Channel *c) anope_override
void OnJoinChannel(User *u, Channel *c) override
{
if (Config->GetModule(this)->Get<bool>("restoreonrecover"))
{
+10 -10
View File
@@ -23,7 +23,7 @@ class CommandNSConfirm : public Command
this->AllowUnregistered(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &passcode = params[0];
@@ -88,7 +88,7 @@ class CommandNSConfirm : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -106,7 +106,7 @@ class CommandNSConfirm : public Command
return true;
}
void OnSyntaxError(CommandSource &source, const Anope::string &subcommand) anope_override
void OnSyntaxError(CommandSource &source, const Anope::string &subcommand) override
{
source.Reply(NICK_CONFIRM_INVALID);
}
@@ -125,7 +125,7 @@ class CommandNSRegister : public Command
this->AllowUnregistered(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
User *u = source.GetUser();
Anope::string u_nick = source.GetNick();
@@ -263,7 +263,7 @@ class CommandNSRegister : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -313,7 +313,7 @@ class CommandNSResend : public Command
this->SetDesc(_("Resend registration confirmation email"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (!Config->GetModule(this->owner)->Get<const Anope::string>("registration").equals_ci("mail"))
{
@@ -344,7 +344,7 @@ class CommandNSResend : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
if (!Config->GetModule(this->owner)->Get<const Anope::string>("registration").equals_ci("mail"))
return false;
@@ -355,7 +355,7 @@ class CommandNSResend : public Command
return true;
}
void OnServHelp(CommandSource &source) anope_override
void OnServHelp(CommandSource &source) override
{
if (Config->GetModule(this->owner)->Get<const Anope::string>("registration").equals_ci("mail"))
Command::OnServHelp(source);
@@ -380,7 +380,7 @@ class NSRegister : public Module
throw ModuleException("Module " + this->name + " will not load with registration disabled.");
}
void OnNickIdentify(User *u) anope_override
void OnNickIdentify(User *u) override
{
BotInfo *NickServ;
if (unconfirmed.HasExt(u->Account()) && (NickServ = Config->GetClient("NickServ")))
@@ -398,7 +398,7 @@ class NSRegister : public Module
}
}
void OnPreNickExpire(NickAlias *na, bool &expire) anope_override
void OnPreNickExpire(NickAlias *na, bool &expire) override
{
if (unconfirmed.HasExt(na->nc))
{
+3 -3
View File
@@ -23,7 +23,7 @@ class CommandNSResetPass : public Command
this->AllowUnregistered(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const NickAlias *na;
@@ -43,7 +43,7 @@ class CommandNSResetPass : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -73,7 +73,7 @@ class NSResetPass : public Module
throw ModuleException("Not using mail.");
}
EventReturn OnPreCommand(CommandSource &source, Command *command, std::vector<Anope::string> &params) anope_override
EventReturn OnPreCommand(CommandSource &source, Command *command, std::vector<Anope::string> &params) override
{
if (command->name == "nickserv/confirm" && params.size() > 1)
{
+52 -52
View File
@@ -20,13 +20,13 @@ class CommandNSSet : public Command
this->SetSyntax(_("\037option\037 \037parameters\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->OnSyntaxError(source, "");
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -75,13 +75,13 @@ class CommandNSSASet : public Command
this->SetSyntax(_("\037option\037 \037nickname\037 \037parameters\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->OnSyntaxError(source, "");
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -120,7 +120,7 @@ class CommandNSSetPassword : public Command
this->SetSyntax(_("\037new-password\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &param = params[0];
unsigned len = param.length();
@@ -157,7 +157,7 @@ class CommandNSSetPassword : public Command
source.Reply(_("Password for \002%s\002 changed."), source.nc->display.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -176,7 +176,7 @@ class CommandNSSASetPassword : public Command
this->SetSyntax(_("\037nickname\037 \037new-password\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -227,7 +227,7 @@ class CommandNSSASetPassword : public Command
source.Reply(_("Password for \002%s\002 changed."), nc->display.c_str());
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -282,12 +282,12 @@ class CommandNSSetAutoOp : public Command
this->OnSyntaxError(source, "AUTOOP");
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, source.nc->display, params[0]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
BotInfo *bi = Config->GetClient("ChanServ");
this->SendSyntax(source);
@@ -309,12 +309,12 @@ class CommandNSSASetAutoOp : public CommandNSSetAutoOp
this->SetSyntax(_("\037nickname\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, params[0], params[1]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
BotInfo *bi = Config->GetClient("ChanServ");
this->SendSyntax(source);
@@ -382,12 +382,12 @@ class CommandNSSetDisplay : public Command
source.Reply(NICK_SET_DISPLAY_CHANGED, user_na->nc->display.c_str());
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, source.nc->display, params[0]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -406,12 +406,12 @@ class CommandNSSASetDisplay : public CommandNSSetDisplay
this->SetSyntax(_("\037nickname\037 \037new-display\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, params[0], params[1]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -528,12 +528,12 @@ class CommandNSSetEmail : public Command
}
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, source.nc->display, params.size() ? params[0] : "");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -553,12 +553,12 @@ class CommandNSSASetEmail : public CommandNSSetEmail
this->SetSyntax(_("\037nickname\037 \037address\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, params[0], params.size() > 1 ? params[1] : "");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -613,12 +613,12 @@ class CommandNSSetKeepModes : public Command
this->OnSyntaxError(source, "");
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, source.nc->display, params[0]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -638,12 +638,12 @@ class CommandNSSASetKeepModes : public CommandNSSetKeepModes
this->SetSyntax(_("\037nickname\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, params[0], params[1]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -733,12 +733,12 @@ class CommandNSSetKill : public Command
return;
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, source.nc->display, params[0]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -767,12 +767,12 @@ class CommandNSSASetKill : public CommandNSSetKill
this->SetSyntax(_("\037nickname\037 {ON | QUICK | IMMED | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, params[0], params[1]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -843,12 +843,12 @@ class CommandNSSetLanguage : public Command
source.Reply(_("Language for \002%s\002 changed to \002%s\002."), nc->display.c_str(), Language::Translate(param.c_str(), _("English")));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &param) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &param) override
{
this->Run(source, source.nc->display, param[0]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -879,12 +879,12 @@ class CommandNSSASetLanguage : public CommandNSSetLanguage
this->SetSyntax(_("\037nickname\037 \037language\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, params[0], params[1]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -956,12 +956,12 @@ class CommandNSSetMessage : public Command
this->OnSyntaxError(source, "MSG");
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, source.nc->display, params[0]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
Anope::string cmd = source.command;
size_t i = cmd.find_last_of(' ');
@@ -976,7 +976,7 @@ class CommandNSSetMessage : public Command
return true;
}
void OnServHelp(CommandSource &source) anope_override
void OnServHelp(CommandSource &source) override
{
if (Config->GetBlock("options")->Get<bool>("useprivmsg"))
Command::OnServHelp(source);
@@ -992,7 +992,7 @@ class CommandNSSASetMessage : public CommandNSSetMessage
this->SetSyntax(_("\037nickname\037 {ON | OFF}"));
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -1002,7 +1002,7 @@ class CommandNSSASetMessage : public CommandNSSetMessage
return true;
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, params[0], params[1]);
}
@@ -1054,12 +1054,12 @@ class CommandNSSetSecure : public Command
this->OnSyntaxError(source, "SECURE");
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, source.nc->display, params[0]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -1083,12 +1083,12 @@ class CommandNSSASetSecure : public CommandNSSetSecure
this->SetSyntax(_("\037nickname\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, params[0], params[1]);
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -1112,7 +1112,7 @@ class CommandNSSASetNoexpire : public Command
this->SetSyntax(_("\037nickname\037 {ON | OFF}"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (Anope::ReadOnly)
{
@@ -1145,7 +1145,7 @@ class CommandNSSASetNoexpire : public Command
this->OnSyntaxError(source, "NOEXPIRE");
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -1196,7 +1196,7 @@ class NSSet : public Module
{
KeepModes(Module *m, const Anope::string &n) : SerializableExtensibleItem<bool>(m, n) { }
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const anope_override
void ExtensibleSerialize(const Extensible *e, const Serializable *s, Serialize::Data &data) const override
{
SerializableExtensibleItem<bool>::ExtensibleSerialize(e, s, data);
@@ -1216,7 +1216,7 @@ class NSSet : public Module
data["last_modes"] << modes;
}
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) anope_override
void ExtensibleUnserialize(Extensible *e, Serializable *s, Serialize::Data &data) override
{
SerializableExtensibleItem<bool>::ExtensibleUnserialize(e, s, data);
@@ -1265,7 +1265,7 @@ class NSSet : public Module
}
EventReturn OnPreCommand(CommandSource &source, Command *command, std::vector<Anope::string> &params) anope_override
EventReturn OnPreCommand(CommandSource &source, Command *command, std::vector<Anope::string> &params) override
{
NickCore *uac = source.nc;
@@ -1288,7 +1288,7 @@ class NSSet : public Module
return EVENT_CONTINUE;
}
void OnSetCorrectModes(User *user, Channel *chan, AccessGroup &access, bool &give_modes, bool &take_modes) anope_override
void OnSetCorrectModes(User *user, Channel *chan, AccessGroup &access, bool &give_modes, bool &take_modes) override
{
if (chan->ci)
{
@@ -1297,13 +1297,13 @@ class NSSet : public Module
}
}
void OnPreNickExpire(NickAlias *na, bool &expire) anope_override
void OnPreNickExpire(NickAlias *na, bool &expire) override
{
if (noexpire.HasExt(na))
expire = false;
}
void OnNickInfo(CommandSource &source, NickAlias *na, InfoFormatter &info, bool show_hidden) anope_override
void OnNickInfo(CommandSource &source, NickAlias *na, InfoFormatter &info, bool show_hidden) override
{
if (!show_hidden)
return;
@@ -1326,19 +1326,19 @@ class NSSet : public Module
info.AddOption(_("Keep modes"));
}
void OnUserModeSet(const MessageSource &setter, User *u, const Anope::string &mname) anope_override
void OnUserModeSet(const MessageSource &setter, User *u, const Anope::string &mname) override
{
if (u->Account() && setter.GetUser() == u)
u->Account()->last_modes = u->GetModeList();
}
void OnUserModeUnset(const MessageSource &setter, User *u, const Anope::string &mname) anope_override
void OnUserModeUnset(const MessageSource &setter, User *u, const Anope::string &mname) override
{
if (u->Account() && setter.GetUser() == u)
u->Account()->last_modes = u->GetModeList();
}
void OnUserLogin(User *u) anope_override
void OnUserLogin(User *u) override
{
if (keep_modes.HasExt(u->Account()))
{
+7 -7
View File
@@ -42,7 +42,7 @@ struct NSMiscData : MiscData, Serializable
data = d;
}
void Serialize(Serialize::Data &sdata) const anope_override
void Serialize(Serialize::Data &sdata) const override
{
sdata["nc"] << this->object;
sdata["name"] << this->name;
@@ -135,12 +135,12 @@ class CommandNSSetMisc : public Command
}
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, source.nc->display, !params.empty() ? params[0] : "");
}
void OnServHelp(CommandSource &source) anope_override
void OnServHelp(CommandSource &source) override
{
if (descriptions.count(source.command))
{
@@ -149,7 +149,7 @@ class CommandNSSetMisc : public Command
}
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
if (descriptions.count(source.command))
{
@@ -170,7 +170,7 @@ class CommandNSSASetMisc : public CommandNSSetMisc
this->SetSyntax(_("\037nickname\037 [\037parameter\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
this->Run(source, params[0], params.size() > 1 ? params[1] : "");
}
@@ -195,7 +195,7 @@ class NSSetMisc : public Module
delete it->second;
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
descriptions.clear();
@@ -218,7 +218,7 @@ class NSSetMisc : public Module
}
}
void OnNickInfo(CommandSource &source, NickAlias *na, InfoFormatter &info, bool) anope_override
void OnNickInfo(CommandSource &source, NickAlias *na, InfoFormatter &info, bool) override
{
for (Anope::map<ExtensibleItem<NSMiscData> *>::iterator it = items.begin(); it != items.end(); ++it)
{
+2 -2
View File
@@ -21,7 +21,7 @@ class CommandNSStatus : public Command
this->AllowUnregistered(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &nick = !params.empty() ? params[0] : source.GetNick();
const NickAlias *na = NickAlias::Find(nick);
@@ -48,7 +48,7 @@ class CommandNSStatus : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+9 -9
View File
@@ -18,7 +18,7 @@ struct NSSuspendInfo : SuspendInfo, Serializable
{
NSSuspendInfo(Extensible *) : Serializable("NSSuspendInfo") { }
void Serialize(Serialize::Data &data) const anope_override
void Serialize(Serialize::Data &data) const override
{
data["nick"] << what;
data["by"] << by;
@@ -61,7 +61,7 @@ class CommandNSSuspend : public Command
this->SetSyntax(_("\037nickname\037 [+\037expiry\037] [\037reason\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &nick = params[0];
@@ -140,7 +140,7 @@ class CommandNSSuspend : public Command
FOREACH_MOD(OnNickSuspend, (na));
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -161,7 +161,7 @@ class CommandNSUnSuspend : public Command
this->SetSyntax(_("\037nickname\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &nick = params[0];
@@ -192,7 +192,7 @@ class CommandNSUnSuspend : public Command
FOREACH_MOD(OnNickUnsuspended, (na));
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -229,14 +229,14 @@ class NSSuspend : public Module
{
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
Anope::string s = conf->GetModule(this)->Get<Anope::string>("show");
commasepstream(s).GetTokens(show);
std::transform(show.begin(), show.end(), show.begin(), trim());
}
void OnNickInfo(CommandSource &source, NickAlias *na, InfoFormatter &info, bool show_hidden) anope_override
void OnNickInfo(CommandSource &source, NickAlias *na, InfoFormatter &info, bool show_hidden) override
{
NSSuspendInfo *s = suspend.Get(na->nc);
if (!s)
@@ -254,7 +254,7 @@ class NSSuspend : public Module
info[_("Suspension expires")] = Anope::strftime(s->expires, source.GetAccount());
}
void OnPreNickExpire(NickAlias *na, bool &expire) anope_override
void OnPreNickExpire(NickAlias *na, bool &expire) override
{
NSSuspendInfo *s = suspend.Get(na->nc);
if (!s)
@@ -274,7 +274,7 @@ class NSSuspend : public Module
}
}
EventReturn OnNickValidate(User *u, NickAlias *na) anope_override
EventReturn OnNickValidate(User *u, NickAlias *na) override
{
NSSuspendInfo *s = suspend.Get(na->nc);
if (!s)
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandNSUpdate : public Command
this->RequireUser(true);
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
User *u = source.GetUser();
NickAlias *na = NickAlias::Find(u->nick);
@@ -36,7 +36,7 @@ class CommandNSUpdate : public Command
source.Reply(_("Status updated (memos, vhost, chmodes, flags)."));
}
bool OnHelp(CommandSource &source, const Anope::string &) anope_override
bool OnHelp(CommandSource &source, const Anope::string &) override
{
this->SendSyntax(source);
source.Reply(" ");
+4 -4
View File
@@ -33,7 +33,7 @@ class AkillDelCallback : public NumberList
source.Reply(_("Deleted %d entries from the AKILL list."), deleted);
}
void HandleNumber(unsigned number) anope_override
void HandleNumber(unsigned number) override
{
if (!number)
return;
@@ -271,7 +271,7 @@ class CommandOSAKill : public Command
{
}
void HandleNumber(unsigned number) anope_override
void HandleNumber(unsigned number) override
{
if (!number)
return;
@@ -390,7 +390,7 @@ class CommandOSAKill : public Command
this->SetSyntax("CLEAR");
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &cmd = params[0];
@@ -413,7 +413,7 @@ class CommandOSAKill : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -22,7 +22,7 @@ class CommandOSChanKill : public Command
this->SetSyntax(_("[+\037expiry\037] \037channel\037 \037reason\037"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
if (!akills)
return;
@@ -93,7 +93,7 @@ class CommandOSChanKill : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+2 -2
View File
@@ -20,7 +20,7 @@ class CommandOSConfig : public Command
this->SetSyntax(_("{\037MODIFY\037|\037VIEW\037} [\037block name\037 \037item name\037 \037item value\037]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &what = params[0];
@@ -117,7 +117,7 @@ class CommandOSConfig : public Command
this->OnSyntaxError(source, what);
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
+10 -10
View File
@@ -120,7 +120,7 @@ class DefConTimeout : public Timer
timeout = NULL;
}
void Tick(time_t) anope_override
void Tick(time_t) override
{
if (DConfig.defaultlevel != level)
{
@@ -177,7 +177,7 @@ class CommandOSDefcon : public Command
this->SetSyntax(_("[\0021\002|\0022\002|\0023\002|\0024\002|\0025\002]"));
}
void Execute(CommandSource &source, const std::vector<Anope::string> &params) anope_override
void Execute(CommandSource &source, const std::vector<Anope::string> &params) override
{
const Anope::string &lvl = params[0];
@@ -233,7 +233,7 @@ class CommandOSDefcon : public Command
return;
}
bool OnHelp(CommandSource &source, const Anope::string &subcommand) anope_override
bool OnHelp(CommandSource &source, const Anope::string &subcommand) override
{
this->SendSyntax(source);
source.Reply(" ");
@@ -335,7 +335,7 @@ class OSDefcon : public Module
}
void OnReload(Configuration::Conf *conf) anope_override
void OnReload(Configuration::Conf *conf) override
{
Configuration::Block *block = conf->GetModule(this);
DefconConfig dconfig;
@@ -406,7 +406,7 @@ class OSDefcon : public Module
this->ParseModeString();
}
EventReturn OnChannelModeSet(Channel *c, MessageSource &source, ChannelMode *mode, const Anope::string &param) anope_override
EventReturn OnChannelModeSet(Channel *c, MessageSource &source, ChannelMode *mode, const Anope::string &param) override
{
if (DConfig.Check(DEFCON_FORCE_CHAN_MODES) && DConfig.DefConModesOff.count(mode->name) && source.GetUser() && !source.GetBot())
{
@@ -418,7 +418,7 @@ class OSDefcon : public Module
return EVENT_CONTINUE;
}
EventReturn OnChannelModeUnset(Channel *c, MessageSource &source, ChannelMode *mode, const Anope::string &) anope_override
EventReturn OnChannelModeUnset(Channel *c, MessageSource &source, ChannelMode *mode, const Anope::string &) override
{
if (DConfig.Check(DEFCON_FORCE_CHAN_MODES) && DConfig.DefConModesOn.count(mode->name) && source.GetUser() && !source.GetBot())
{
@@ -436,7 +436,7 @@ class OSDefcon : public Module
return EVENT_CONTINUE;
}
EventReturn OnPreCommand(CommandSource &source, Command *command, std::vector<Anope::string> &params) anope_override
EventReturn OnPreCommand(CommandSource &source, Command *command, std::vector<Anope::string> &params) override
{
if (DConfig.Check(DEFCON_OPER_ONLY) && !source.IsOper())
{
@@ -483,7 +483,7 @@ class OSDefcon : public Module
return EVENT_CONTINUE;
}
void OnUserConnect(User *u, bool &exempt) anope_override
void OnUserConnect(User *u, bool &exempt) override
{
if (exempt || u->Quitting() || !u->server->IsSynced() || u->server->IsULined())
return;
@@ -535,13 +535,13 @@ class OSDefcon : public Module
}
}
void OnChannelModeAdd(ChannelMode *cm) anope_override
void OnChannelModeAdd(ChannelMode *cm) override
{
if (DConfig.chanmodes.find(cm->mchar) != Anope::string::npos)
this->ParseModeString();
}
void OnChannelSync(Channel *c) anope_override
void OnChannelSync(Channel *c) override
{
if (DConfig.Check(DEFCON_FORCE_CHAN_MODES))
c->SetModes(Config->GetClient("OperServ"), false, "%s", DConfig.chanmodes.c_str());

Some files were not shown because too many files have changed in this diff Show More