]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - include/users.h
Updated header comments
[user/henk/code/inspircd.git] / include / users.h
index c1a6aa3afae4ab0277d7b3bad3c70b61ee9fdd23..7b1e7ccc4a7480db96da55265b4e506ac9b17032 100644 (file)
@@ -1,7 +1,18 @@
-/*
-
-
-*/
+/*       +------------------------------------+
+ *       | Inspire Internet Relay Chat Daemon |
+ *       +------------------------------------+
+ *
+ *  Inspire is copyright (C) 2002-2004 ChatSpike-Dev.
+ *                       E-mail:
+ *                <brain@chatspike.net>
+ *               <Craig@chatspike.net>
+ *     
+ * Written by Craig Edwards, Craig McLure, and others.
+ * This program is free but copyrighted software; see
+ *            the file COPYING for details.
+ *
+ * ---------------------------------------------------
+ */
 
 #include "inspircd_config.h" 
 #include "channels.h"
@@ -136,6 +147,13 @@ class userrec : public connection
         * will be disconnected
         */
        unsigned long timeout;
+       
+       /** The oper type they logged in as, if they are an oper.
+        * This is used to check permissions in operclasses, so that
+        * we can say 'yay' or 'nay' to any commands they issue.
+        * The value of this is the value of a valid 'type name=' tag.
+        */
+       char oper[NICKMAX];
 
        userrec();
        
@@ -168,6 +186,12 @@ class userrec : public connection
         */
        virtual void RemoveInvite(char* channel);
        
+       /** Returns true or false for if a user can execute a privilaged oper command.
+        * This is done by looking up their oper type from userrec::oper, then referencing
+        * this to their oper classes and checking the commands they can execute.
+        */
+       bool HasPermission(char* command);
+       
 };