diff options
Diffstat (limited to 'include/modules/protocol/unreal.h')
-rw-r--r-- | include/modules/protocol/unreal.h | 232 |
1 files changed, 195 insertions, 37 deletions
diff --git a/include/modules/protocol/unreal.h b/include/modules/protocol/unreal.h index 0a01cb4be..9039cc2cd 100644 --- a/include/modules/protocol/unreal.h +++ b/include/modules/protocol/unreal.h @@ -22,79 +22,237 @@ namespace unreal { -class Proto : public IRCDProto +namespace senders +{ + +class Akill : public messages::Akill { public: - Proto(Module *creator); + using messages::Akill::Akill; - private: - void SendSVSNOOP(Server *server, bool set) override; + void Send(User *, XLine *) override; +}; + +class AkillDel : public messages::AkillDel +{ + public: + using messages::AkillDel::AkillDel; + + void Send(XLine *) override; +}; + +class MessageChannel : public messages::MessageChannel +{ + public: + using messages::MessageChannel::MessageChannel; + + void Send(Channel *) override; +}; - void SendAkillDel(XLine *x) override; +class Join : public messages::Join +{ + public: + using messages::Join::Join; - void SendTopic(const MessageSource &source, Channel *c) override; + void Send(User *u, Channel *c, const ChannelStatus *status) override; +}; - void SendGlobalNotice(ServiceBot *bi, Server *dest, const Anope::string &msg) override; +class Login : public messages::Login +{ + public: + using messages::Login::Login; - void SendGlobalPrivmsg(ServiceBot *bi, Server *dest, const Anope::string &msg) override; + void Send(User *u, NickServ::Nick *na) override; +}; - void SendVhostDel(User *u) override; +class Logout : public messages::Logout +{ + public: + using messages::Logout::Logout; - void SendAkill(User *u, XLine *x) override; + void Send(User *u) override; +}; - void SendSVSKill(const MessageSource &source, User *user, const Anope::string &buf) override; +class Kill : public messages::Kill +{ + public: + using messages::Kill::Kill; - void SendMode(const MessageSource &source, User *u, const Anope::string &buf) override; + void Send(const MessageSource &source, const Anope::string &target, const Anope::string &reason) override; - void SendClientIntroduction(User *u) override; + void Send(const MessageSource &source, User *user, const Anope::string &reason) override; +}; - void SendServer(Server *server) override; +class ModeUser : public messages::ModeUser +{ + public: + using messages::ModeUser::ModeUser; - void SendJoin(User *user, Channel *c, const ChannelStatus *status) override; + void Send(const MessageSource &source, User *user, const Anope::string &modes) override; +}; - void SendSQLineDel(XLine *x) override; +class NickIntroduction : public messages::NickIntroduction +{ + public: + using messages::NickIntroduction::NickIntroduction; - void SendSQLine(User *, XLine *x) override; + void Send(User *user) override; +}; - void SendVhost(User *u, const Anope::string &vIdent, const Anope::string &vhost) override; +class SASL : public messages::SASL +{ + public: + using messages::SASL::SASL; - void SendConnect() override; + void Send(const ::SASL::Message &) override; +}; - void SendSVSHold(const Anope::string &nick, time_t t) override; +class MessageServer : public messages::MessageServer +{ + public: + using messages::MessageServer::MessageServer; - void SendSVSHoldDel(const Anope::string &nick) override; + void Send(Server *server) override; +}; - void SendSGLineDel(XLine *x) override; +class SGLine : public messages::SGLine +{ + public: + using messages::SGLine::SGLine; - void SendSZLineDel(XLine *x) override; + void Send(User *, XLine *) override; +}; - void SendSZLine(User *, XLine *x) override; +class SGLineDel : public messages::SGLineDel +{ + public: + using messages::SGLineDel::SGLineDel; - void SendSGLine(User *, XLine *x) override; + void Send(XLine *) override; +}; - void SendSVSJoin(const MessageSource &source, User *user, const Anope::string &chan, const Anope::string ¶m) override; +class SQLine : public messages::SQLine +{ + public: + using messages::SQLine::SQLine; - void SendSVSPart(const MessageSource &source, User *user, const Anope::string &chan, const Anope::string ¶m) override; + void Send(User *, XLine *) override; +}; - void SendSWhois(const MessageSource &source, const Anope::string &who, const Anope::string &mask) override; +class SQLineDel : public messages::SQLineDel +{ + public: + using messages::SQLineDel::SQLineDel; - void SendEOB() override; + void Send(XLine *) override; +}; - bool IsNickValid(const Anope::string &nick) override; +class SZLine : public messages::SZLine +{ + public: + using messages::SZLine::SZLine; - bool IsChannelValid(const Anope::string &chan) override; + void Send(User *, XLine *) override; +}; - bool IsExtbanValid(const Anope::string &mask) override; +class SZLineDel : public messages::SZLineDel +{ + public: + using messages::SZLineDel::SZLineDel; + + void Send(XLine *) override; +}; + +class SVSHold : public messages::SVSHold +{ + public: + using messages::SVSHold::SVSHold; + + void Send(const Anope::string &, time_t) override; +}; + +class SVSHoldDel : public messages::SVSHoldDel +{ + public: + using messages::SVSHoldDel::SVSHoldDel; + + void Send(const Anope::string &) override; +}; + +class SVSJoin : public messages::SVSJoin +{ + public: + using messages::SVSJoin::SVSJoin; + + void Send(const MessageSource &source, User *u, const Anope::string &chan, const Anope::string &key) override; +}; + +class SVSLogin : public messages::SVSLogin +{ + public: + using messages::SVSLogin::SVSLogin; + + void Send(const Anope::string &uid, const Anope::string &acc, const Anope::string &vident, const Anope::string &vhost) override; +}; + +class SVSPart : public messages::SVSPart +{ + public: + using messages::SVSPart::SVSPart; + + void Send(const MessageSource &source, User *u, const Anope::string &chan, const Anope::string &reason) override; +}; + +class SWhois : public messages::SWhois +{ + public: + using messages::SWhois::SWhois; + + void Send(const MessageSource &, User *user, const Anope::string &) override; +}; + +class Topic : public messages::Topic +{ + public: + using messages::Topic::Topic; + + void Send(const MessageSource &source, Channel *channel, const Anope::string &topic, time_t topic_ts, const Anope::string &topic_setter) override; +}; + +class VhostDel : public messages::VhostDel +{ + public: + using messages::VhostDel::VhostDel; + + void Send(User *u) override; +}; + +class VhostSet : public messages::VhostSet +{ + public: + using messages::VhostSet::VhostSet; + + void Send(User *u, const Anope::string &vident, const Anope::string &vhost) override; +}; - void SendLogin(User *u, NickServ::Nick *na) override; +} // namespace senders - void SendLogout(User *u) override; +class Proto : public IRCDProto +{ + public: + Proto(Module *creator); - void SendChannel(Channel *c) override; + private: - void SendSASLMessage(const ::SASL::Message &message) override; + void Handshake() override; - void SendSVSLogin(const Anope::string &uid, const Anope::string &acc, const Anope::string &vident, const Anope::string &vhost) override; + void SendEOB() override; + + bool IsNickValid(const Anope::string &nick) override; + + bool IsChannelValid(const Anope::string &chan) override; + + bool IsExtbanValid(const Anope::string &mask) override; bool IsIdentValid(const Anope::string &ident) override; }; |