summaryrefslogtreecommitdiff
path: root/include/protocol.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/protocol.h')
-rw-r--r--include/protocol.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/include/protocol.h b/include/protocol.h
index 612593c89..aeac6a069 100644
--- a/include/protocol.h
+++ b/include/protocol.h
@@ -16,6 +16,17 @@
#include "service.h"
#include "modes.h"
+/** Thrown when a protocol error happens. */
+class CoreExport ProtocolException final
+ : public ModuleException
+{
+public:
+ ProtocolException(const Anope::string &message)
+ : ModuleException(message)
+ {
+ }
+};
+
/* Encapsulates the IRCd protocol we are speaking. */
class CoreExport IRCDProto
: public Service
@@ -109,6 +120,11 @@ public:
virtual Anope::string UID_Retrieve();
virtual Anope::string SID_Retrieve();
+ /** Sends an error to the uplink before disconnecting.
+ * @param reason The error message.
+ */
+ virtual void SendError(const Anope::string &reason);
+
/** Sets the server in NOOP mode. If NOOP mode is enabled, no users
* will be able to oper on the server.
* @param s The server