BetterMembership.Web.ExtendedMembershipProviderExtensions.IsAccountLockedOut C# (CSharp) Метод

IsAccountLockedOut() публичный статический Метод

public static IsAccountLockedOut ( this provider, string userName, int allowedPasswordAttempts, System.TimeSpan interval ) : bool
provider this
userName string
allowedPasswordAttempts int
interval System.TimeSpan
Результат bool
        public static bool IsAccountLockedOut(
            this ExtendedMembershipProvider provider, string userName, int allowedPasswordAttempts, TimeSpan interval)
        {
            return provider.GetUser(userName, false) != null
                   && provider.GetPasswordFailuresSinceLastSuccess(userName) > allowedPasswordAttempts
                   && provider.GetLastPasswordFailureDate(userName).Add(interval) > DateTime.UtcNow;
        }

Same methods

ExtendedMembershipProviderExtensions::IsAccountLockedOut ( this provider, string userName, int allowedPasswordAttempts, int intervalSeconds ) : bool
ExtendedMembershipProviderExtensions