diff options
| author | Roy Ben-Shabat <Roy@Twine-s.com> | 2018-06-14 15:57:24 +0300 |
|---|---|---|
| committer | Roy Ben-Shabat <Roy@Twine-s.com> | 2018-06-14 15:57:24 +0300 |
| commit | a775178c063082eb6a401b4254a046133840af03 (patch) | |
| tree | 4ba9572da806e6e5ec031853188f6f335546fb57 /Software/Visual_Studio/PPC/Tango.PPC.UI/Authentication/DefaultAuthenticationProvider.cs | |
| parent | 099cb04861e293cf675d8b5216448a766eef7954 (diff) | |
| download | Tango-a775178c063082eb6a401b4254a046133840af03.tar.gz Tango-a775178c063082eb6a401b4254a046133840af03.zip | |
Working on PPC...
Diffstat (limited to 'Software/Visual_Studio/PPC/Tango.PPC.UI/Authentication/DefaultAuthenticationProvider.cs')
| -rw-r--r-- | Software/Visual_Studio/PPC/Tango.PPC.UI/Authentication/DefaultAuthenticationProvider.cs | 25 |
1 files changed, 22 insertions, 3 deletions
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/Authentication/DefaultAuthenticationProvider.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/Authentication/DefaultAuthenticationProvider.cs index 8a60caf6d..53a37c7f5 100644 --- a/Software/Visual_Studio/PPC/Tango.PPC.UI/Authentication/DefaultAuthenticationProvider.cs +++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/Authentication/DefaultAuthenticationProvider.cs @@ -10,10 +10,22 @@ using Tango.PPC.Common.Authentication; namespace Tango.PPC.UI.Authentication { + /// <summary> + /// Represents the default PPC authentication provider. + /// </summary> + /// <seealso cref="Tango.Core.ExtendedObject" /> + /// <seealso cref="Tango.PPC.Common.Authentication.IAuthenticationProvider" /> public class DefaultAuthenticationProvider : ExtendedObject, IAuthenticationProvider { - private User _currentUser; + /// <summary> + /// Occurs when the current logged-in user has changed. + /// </summary> + public event EventHandler<User> CurrentUserChanged; + private User _currentUser; + /// <summary> + /// Gets the current logged-in user. + /// </summary> public User CurrentUser { get { return _currentUser; } @@ -24,8 +36,12 @@ namespace Tango.PPC.UI.Authentication } } - public event EventHandler<User> CurrentUserChanged; - + /// <summary> + /// Performs a user login by the specified email and password. + /// </summary> + /// <param name="email">The email.</param> + /// <param name="password">The password.</param> + /// <returns></returns> public Task<User> Login(string email, string password) { return Task.Factory.StartNew(() => @@ -36,6 +52,9 @@ namespace Tango.PPC.UI.Authentication }); } + /// <summary> + /// Logs-out the current logged-in user. + /// </summary> public void Logout() { CurrentUser = null; |
