X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=include%2Fmessage.h;h=1624a1de42df747410247dc162bd08e690bfec87;hb=daf3be301d0181d14d1310b3ab5f79c8a85dfb46;hp=8c7c7592a06eb1f3139655371c75871aa8e92b4d;hpb=c5c5a867d29c98c73e4f9cc67841617c2598a320;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/include/message.h b/include/message.h index 8c7c7592a..1624a1de4 100644 --- a/include/message.h +++ b/include/message.h @@ -56,6 +56,24 @@ class CoreExport MessageDetails /** The type of message. */ const MessageType type; + /** Determines whether the specified message is a CTCP. If the specified message + * is a CTCP then the CTCP name and CTCP body are extracted and stored in the + * name and body references. + * @param name The location to store the parsed CTCP name. + * @param body The location to store the parsed CTCP body. + */ + virtual bool IsCTCP(std::string& name, std::string& body) const = 0; + + /** Determines whether the specified message is a CTCP. If the specified message + * is a CTCP then the CTCP name is extracted and stored in the name reference. + * @param name The location to store the parsed CTCP name. + */ + virtual bool IsCTCP(std::string& name) const = 0; + + /** Determines whether the specified message is a CTCP. */ + virtual bool IsCTCP() const = 0; + + protected: MessageDetails(MessageType mt, const std::string& msg, const ClientProtocol::TagMap& tags) : echo(true) , echo_original(false)