X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=include%2Fmodules.h;h=fe921a5405d729e53eb28f7a2df454a2e07b1049;hb=276bbd193ed9dc53f44a4f564401d577d8e31424;hp=7655517ea79dcbb9f9b8d6479c880eee07de2223;hpb=3ec7995bf4981119115d14ce2cfce0cb5795f803;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/include/modules.h b/include/modules.h index 7655517ea..fe921a540 100644 --- a/include/modules.h +++ b/include/modules.h @@ -75,7 +75,7 @@ enum MessageType { * ipv4 servers, so this value will be ten times as * high on ipv6 servers. */ -#define NATIVE_API_VERSION 11020 +#define NATIVE_API_VERSION 11022 #ifdef IPV6 #define API_VERSION (NATIVE_API_VERSION * 10) #else @@ -791,8 +791,10 @@ class Module : public Extensible * @param proto A pointer to the module handling network protocol * @param opaque An opaque pointer set by the protocol module, should not be modified! * @param extname The extensions name which is being searched for + * @param displayable If this value is true, the data is going to be displayed to a user, + * and not sent across the network. Use this to determine wether or not to show sensitive data. */ - virtual void OnSyncChannelMetaData(chanrec* chan, Module* proto,void* opaque, const std::string &extname); + virtual void OnSyncChannelMetaData(chanrec* chan, Module* proto,void* opaque, const std::string &extname, bool displayable = false); /* Allows modules to syncronize metadata related to users over the network during a netburst. * Whenever the linking module wants to send out data, but doesnt know what the data @@ -804,8 +806,10 @@ class Module : public Extensible * @param proto A pointer to the module handling network protocol * @param opaque An opaque pointer set by the protocol module, should not be modified! * @param extname The extensions name which is being searched for + * @param displayable If this value is true, the data is going to be displayed to a user, + * and not sent across the network. Use this to determine wether or not to show sensitive data. */ - virtual void OnSyncUserMetaData(userrec* user, Module* proto,void* opaque, const std::string &extname); + virtual void OnSyncUserMetaData(userrec* user, Module* proto,void* opaque, const std::string &extname, bool displayable = false); /* Allows modules to syncronize metadata not related to users or channels, over the network during a netburst. * Whenever the linking module wants to send out data, but doesnt know what the data @@ -815,8 +819,10 @@ class Module : public Extensible * if it belongs to your module. * @param proto A pointer to the module handling network protocol * @param opaque An opaque pointer set by the protocol module, should not be modified! + * @param displayable If this value is true, the data is going to be displayed to a user, + * and not sent across the network. Use this to determine wether or not to show sensitive data. */ - virtual void OnSyncOtherMetaData(Module* proto, void* opaque); + virtual void OnSyncOtherMetaData(Module* proto, void* opaque, bool displayable = false); /** Allows module data, sent via ProtoSendMetaData, to be decoded again by a receiving module. * Please see src/modules/m_swhois.cpp for a working example of how to use this method call. @@ -1338,7 +1344,7 @@ class Module : public Extensible * and if you do you must return 1. If you do not handle the names list, * return 0. */ - virtual int OnUserList(userrec* user, chanrec* Ptr); + virtual int OnUserList(userrec* user, chanrec* Ptr, CUList* &userlist); /** Called whenever a line of WHOIS output is sent to a user. * You may change the numeric and the text of the output by changing