X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=include%2Fusermanager.h;h=a67f90224d628839eda4c05a6f7feac53e08cd11;hb=5544649cd2058ba6d30925e61d20ae4a0245c0fa;hp=2f77e8333239a7e0c4b2c390779be0d1df5d01db;hpb=bc8664c5c49f4ac9adbc5e3937a584e4a6b35614;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/include/usermanager.h b/include/usermanager.h index 2f77e8333..a67f90224 100644 --- a/include/usermanager.h +++ b/include/usermanager.h @@ -41,7 +41,7 @@ class CoreExport UserManager : public fakederef /** A list holding local users */ - typedef intrusive_list LocalList; + typedef insp::intrusive_list LocalList; private: /** Map of IP addresses for clone counting @@ -52,6 +52,10 @@ class CoreExport UserManager : public fakederef */ const CloneCounts zeroclonecounts; + /** Local client list, a list containing only local clients + */ + LocalList local_users; + public: /** Constructor, initializes variables */ @@ -70,10 +74,6 @@ class CoreExport UserManager : public fakederef */ user_hash uuidlist; - /** Local client list, a list containing only local clients - */ - LocalList local_users; - /** Oper list, a vector containing all local and remote opered users */ OperList all_opers; @@ -130,6 +130,10 @@ class CoreExport UserManager : public fakederef */ void RemoveCloneCounts(User *user); + /** Rebuild clone counts + */ + void RehashCloneCounts(); + /** Return the number of local and global clones of this user * @param user The user to get the clone counts for * @return The clone counts of this user. The returned reference is volatile - you @@ -173,6 +177,11 @@ class CoreExport UserManager : public fakederef */ user_hash& GetUsers() { return clientlist; } + /** Get a list containing all local users + * @return A const list of local users + */ + const LocalList& GetLocalUsers() const { return local_users; } + /** Send a server notice to all local users * @param text The text format string to send * @param ... The format arguments