RMS SDK for C++  0.2.1
A client library for using Microsoft RMS from Linux.
UserRights.h
1 /*
2  * ======================================================================
3  * Copyright (c) Microsoft Open Technologies, Inc. All rights reserved.
4  * Licensed under the MIT License.
5  * See LICENSE.md in the project root for license information.
6  * ======================================================================
7 */
8 
9 #ifndef USERRIGHTS
10 #define USERRIGHTS
11 #include <vector>
12 #include <string>
13 #include "ModernAPIExport.h"
14 
15 namespace rmscore {
16 namespace modernapi {
17 typedef std::vector<std::string> UserList;
18 typedef std::vector<std::string> RightList;
19 
23 class DLL_PUBLIC_RMS UserRights {
24 public:
25 
29  UserRights(const UserList& users, const RightList& rights) : users(users),
30  rights(rights) {}
31 
35  const UserList& Users() const
36  {
37  return this->users;
38  }
39 
43  const RightList& Rights() const
44  {
45  return this->rights;
46  }
47 
48 private:
49 
50  UserList users;
51  RightList rights;
52 
53 private:
54 
55  void ValidateUsers(UserList& users);
56  void ValidateRights(RightList& rights);
57 };
58 } // namespace modernapi
59 } // namespace rmscore
60 
61 
62 #endif // USERRIGHTS
UserRights(const UserList &users, const RightList &rights)
Creates a UserRights object.
Definition: UserRights.h:29
const RightList & Rights() const
The granted rights.
Definition: UserRights.h:43
Definition: AuthenticationCallbackImpl.h:16
const UserList & Users() const
The users to whom the rights are granted.
Definition: UserRights.h:35
Supplies properties for users and their granted rights.
Definition: UserRights.h:23