[project @ 2005-06-28 03:16:45 by unknown_lamer]
[clinton/bobotpp.git] / source / User.H
CommitLineData
cb21075d 1// User.H -*- C++ -*-
2// Copyright (c) 1997, 1998 Etienne BERNARD
3
4// This program is free software; you can redistribute it and/or modify
5// it under the terms of the GNU General Public License as published by
6// the Free Software Foundation; either version 2 of the License, or
7// any later version.
8
9// This program is distributed in the hope that it will be useful,
10// but WITHOUT ANY WARRANTY; without even the implied warranty of
11// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12// GNU General Public License for more details.
13
14// You should have received a copy of the GNU General Public License
15// along with this program; if not, write to the Free Software
39b022cb 16// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
cb21075d 17
18#ifndef USER_H
19#define USER_H
20
21#include "UserList.H"
22#include "UserListItem.H"
23
24class Bot;
cb21075d 25class Parser;
26class Channel;
27class Commands;
28class UserCommands;
29
30class User {
31
32 int mode;
33 int floodNum;
34 UserListItem * userListItem;
35 String nick;
36 String userhost;
37 String userkey;
38
39public:
40 enum {
41 OP_MODE = 1,
42 VOICE_MODE = 2,
43 AWAY_MODE = 4,
44 IRCOP_MODE = 8
45 };
46
47 enum {
48 NONE = 0,
49 USER = 1,
50 TRUSTED_USER = 2,
51 FRIEND = 3,
52 MASTER = 4
53 };
54
55 enum {
56 NO_PROT = 0,
57 NO_BAN = 1,
58 NO_KICK = 2,
59 NO_DEOP = 3
60 };
61
62 User(String, String, String, int, UserList *);
63 User(String, int);
64
65 int getLevel();
66 int getProt();
67 bool getAop();
68
69 friend class Bot;
cb21075d 70 friend class Parser;
71 friend class Channel;
72 friend class Commands;
73 friend class UserCommands;
74};
75
76#endif