X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=include%2Fxline.h;h=886034bbafd81df76658a621dc28bf3b9ea0ef8e;hb=0d3ecb964292600ec1ce6ee1cef83f72185a8bcc;hp=d5653f8e0558b16b9913fdadc369198439389e5c;hpb=f1271614679843191bb247c0db2716acb5ac0e4b;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/include/xline.h b/include/xline.h index d5653f8e0..886034bba 100644 --- a/include/xline.h +++ b/include/xline.h @@ -142,6 +142,8 @@ class CoreExport XLine : public classbase * type of line this is. */ const std::string type; + + virtual bool IsBurstable(); }; /** KLine class @@ -184,6 +186,8 @@ class CoreExport KLine : public XLine virtual const char* Displayable(); + virtual bool IsBurstable(); + /** Ident mask (ident part only) */ char* identmask; @@ -381,7 +385,7 @@ typedef std::pair IdentHostPair; * does not have to know the specifics of the internals of an XLine class * and/or how to call its constructor. */ -class CoreExport XLineFactory +class CoreExport XLineFactory : public classbase { protected: @@ -411,6 +415,8 @@ class CoreExport XLineFactory */ virtual XLine* Generate(time_t set_time, long duration, const char* source, const char* reason, const char* xline_specific_mask) = 0; + virtual bool AutoApplyToUserList(XLine* x) { return true; } + /** Destructor */ virtual ~XLineFactory() { } @@ -433,7 +439,7 @@ typedef std::map XLineFactMap; /** A map of XLines indexed by string */ -typedef std::map XLineLookup; +typedef std::map XLineLookup; /** A map of XLineLookup maps indexed by string */ @@ -451,7 +457,7 @@ typedef XLineLookup::iterator LookupIter; * or any other line created by a module. It also manages XLineFactory classes which * can generate a specialized XLine for use by another module. */ -class CoreExport XLineManager +class CoreExport XLineManager : public classbase { protected: /** The owner/creator of this class @@ -511,6 +517,10 @@ class CoreExport XLineManager */ XLineLookup* GetAll(const std::string &type); + /** Remove all lines of a certain type. + */ + void DelAll(const std::string &type); + /** Return all known types of line currently stored by the XLineManager. * @return A vector containing all known line types currently stored in the main list. */