IUsersManager.h
Go to the documentation of this file.
1 #ifndef iauth_IUsersManager_included
2 #define iauth_IUsersManager_included
3 
4 
5 // Qt includes
6 #include <QtCore/QVector>
7 
8 // ACF includes
9 #include <QtCore/QString>
10 #include "iser/ISerializable.h"
11 
12 // ACF-Solutions includes
13 #include "iauth/CUser.h"
14 
15 
16 namespace iauth
17 {
18 
19 
24 {
25 public:
29  virtual int GetUsersCount() const = 0;
30 
35  virtual int FindUserIndex(const QString& name) const = 0;
36 
40  virtual const CUser& GetUser(int index) const = 0;
41 
45  virtual CUser& GetUserRef(int index) = 0;
46 
52  virtual CUser* AddUser(const QString& userName) = 0;
53 
59  virtual bool DeleteUser(const QString& userName) = 0;
60 
69  virtual bool RenameUser(int userIndex, const QString& userName) = 0;
70 
74  virtual int GetUserGroupsCount() const = 0;
75 
79  virtual const QString& GetUserGroupName(int groupIndex) const = 0;
80 };
81 
82 
83 } // namespace iauth
84 
85 
86 #endif // !iauth_IUsersManager_included
87 
88 
virtual const CUser & GetUser(int index) const =0
Get user using its index.
virtual const QString & GetUserGroupName(int groupIndex) const =0
Get number of user groups.
virtual int GetUsersCount() const =0
Get number of users in this collection.
virtual bool RenameUser(int userIndex, const QString &userName)=0
The method renames the user.
virtual CUser * AddUser(const QString &userName)=0
Add a new user to the user list.
virtual int FindUserIndex(const QString &name) const =0
Search for user with specified name.
virtual CUser & GetUserRef(int index)=0
Get reference to user object using its index.
virtual bool DeleteUser(const QString &userName)=0
Delete the user with the user name.
virtual int GetUserGroupsCount() const =0
Get number of user groups.
Provide management of users.
Definition: IUsersManager.h:23

© 2007-2011 Witold Gantzke and Kirill Lepskiy