RMS SDK for C++  0.2.1
A client library for using Microsoft RMS from Linux.
UserCredential.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 USERCREDENTIAL
10 #define USERCREDENTIAL
11 
12 #include "types.h"
13 #include "rmsauthExport.h"
14 
15 namespace rmsauth {
16 
17 enum class UserAuthType
18 {
19  IntegratedAuth,
20  UsernamePassword
21 };
22 
23 class RMSAUTH_EXPORT UserCredential
24 {
25  UserAuthType userAuthType_;
26  String userName_;
27  String password_;
28 
29 public:
31  UserCredential(const String& userName);
32  UserCredential(const String& userName, const String& password);
33 
34  const String& userName() const { return userName_; }
35  void userName(const String& val) { userName_= val; }
36 
37  UserAuthType userAuthType() const { return userAuthType_; }
38 
39  const String& password() const { return password_; }
40 };
41 
42 using UserCredentialPtr = ptr<UserCredential>;
43 
44 } // namespace rmsauth {
45 
46 #endif // USERCREDENTIAL
Definition: UserCredential.h:23
Definition: AcquireTokenForClientHandler.h:14