X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=include%2Fusermanager.h;h=1ab48925d865b3b3ea42fab3d2094a281ffc0ac8;hb=f3d134a5b642b83e865c03b45c313df7f829ba15;hp=92b40b373ba6b595768f40180945e6c6b04bd6c5;hpb=74ee9af96639323d852a8b15be72ee9974e0a826;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/include/usermanager.h b/include/usermanager.h index 92b40b373..1ab48925d 100644 --- a/include/usermanager.h +++ b/include/usermanager.h @@ -17,8 +17,7 @@ */ -#ifndef USERMANAGER_H -#define USERMANAGER_H +#pragma once #include @@ -52,9 +51,9 @@ class CoreExport UserManager */ user_hash* uuidlist; - /** Local client list, a vector containing only local clients + /** Local client list, a list containing only local clients */ - std::vector local_users; + LocalUserList local_users; /** Oper list, a vector containing all local and remote opered users */ @@ -70,6 +69,12 @@ class CoreExport UserManager */ clonemap global_clones; + /** + * Reset the already_sent IDs so we don't wrap it around and drop a message + * Also removes all expired invites + */ + void GarbageCollect(); + /** Add a client to the system. * This will create a new User, insert it into the user_hash, * initialize it as not yet registered, and add it to the socket engine. @@ -143,9 +148,6 @@ class CoreExport UserManager */ unsigned int LocalUserCount(); - - - /** Number of users with a certain mode set on them */ int ModeCount(const char mode); @@ -155,12 +157,4 @@ class CoreExport UserManager * @param ... The format arguments */ void ServerNoticeAll(const char* text, ...) CUSTOM_PRINTF(2, 3); - - /** Send a server message (PRIVMSG) to all local users - * @param text The text format string to send - * @param ... The format arguments - */ - void ServerPrivmsgAll(const char* text, ...) CUSTOM_PRINTF(2, 3); }; - -#endif