Sic.Framework-Nanjing-Baishi/MECF.Framework.Common/Aitex/Core/Account/CredentialKeepAliveCheckRes...

43 lines
1.0 KiB
C#

using System;
namespace Aitex.Core.Account
{
[Serializable]
public class CredentialKeepAliveCheckResult
{
#region Constructors
public CredentialKeepAliveCheckResult() : this(CredentialKeepAliveStates.NotFound)
{
}
public CredentialKeepAliveCheckResult(CredentialKeepAliveStates state) : this(state, "")
{
State = state;
}
public CredentialKeepAliveCheckResult(CredentialKeepAliveStates state, string userName)
{
State = state;
UserName = userName;
}
#endregion
#region Properties
/// <summary>
/// 返回凭据存活状态。
/// </summary>
public CredentialKeepAliveStates State { get; set; }
/// <summary>
/// 如果<see cref="State"/>等于<see cref="CredentialKeepAliveStates.RequestingLogin"/>,则返回正在发起登录请求的用户名。
/// </summary>
public string UserName { get; set; }
#endregion
}
}