diff options
| author | Adam <Adam@anope.org> | 2012-04-23 05:08:26 -0400 |
|---|---|---|
| committer | Adam <Adam@anope.org> | 2012-04-23 05:08:26 -0400 |
| commit | 573e49a7ead331219eb6f0d3ca9cf83e793a5c9c (patch) | |
| tree | e145e04fa3d041cf92ce46da4ac790b63231059c /include/oper.h | |
| parent | 63c639e108a00d7dbb0d7ac9891684fc83a3b207 (diff) | |
Reworked live SQL support yet again
Diffstat (limited to 'include/oper.h')
| -rw-r--r-- | include/oper.h | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/include/oper.h b/include/oper.h index b3034b7c5..d388c4339 100644 --- a/include/oper.h +++ b/include/oper.h @@ -40,18 +40,18 @@ class CoreExport XLine : public Serializable bool HasNickOrReal() const; bool IsRegex() const; - Anope::string serialize_name() const; - serialized_data serialize(); - static void unserialize(serialized_data &data); + const Anope::string serialize_name() const anope_override; + Serialize::Data serialize() const anope_override; + static Serializable* unserialize(Serializable *obj, Serialize::Data &data); }; class CoreExport XLineManager : public Service { char type; /* List of XLines in this XLineManager */ - std::vector<XLine *> XLines; + serialize_checker<std::vector<XLine *> > XLines; /* Akills can have the same IDs, sometimes */ - static std::multimap<Anope::string, XLine *, ci::less> XLinesByUID; + static serialize_checker<std::multimap<Anope::string, XLine *, ci::less> > XLinesByUID; public: /* List of XLine managers we check users against in XLineManager::CheckAll */ static std::list<XLineManager *> XLineManagers; @@ -118,7 +118,7 @@ class CoreExport XLineManager : public Service * @param index The index * @return The XLine, or NULL if the index is out of bounds */ - XLine *GetEntry(unsigned index); + XLine* GetEntry(unsigned index); /** Clear the XLine vector * Note: This does not remove the XLines from the IRCd @@ -138,7 +138,7 @@ class CoreExport XLineManager : public Service * @param mask The mask * @return The XLine the user matches, or NULL */ - XLine *HasEntry(const Anope::string &mask); + XLine* HasEntry(const Anope::string &mask); /** Check a user against all of the xlines in this XLineManager * @param u The user @@ -150,7 +150,7 @@ class CoreExport XLineManager : public Service * @param u The user * @param x The xline */ - virtual bool Check(User *u, XLine *x) = 0; + virtual bool Check(User *u, const XLine *x) = 0; /** Called when a user matches a xline in this XLineManager * @param u The user @@ -161,7 +161,7 @@ class CoreExport XLineManager : public Service /** Called when an XLine expires * @param x The xline */ - virtual void OnExpire(XLine *x); + virtual void OnExpire(const XLine *x); /** Called to send an XLine to the IRCd * @param u The user, if we know it |
