Class LockedAccountException

  • All Implemented Interfaces:
    java.io.Serializable

    public class LockedAccountException
    extends DisabledAccountException
    A special kind of DisabledAccountException, this exception is thrown when attempting to authenticate and the corresponding account has been disabled explicitly due to being locked.

    For example, an account can be locked if an administrator explicitly locks an account or perhaps an account can be locked automatically by the system if too many unsuccessful authentication attempts take place during a specific period of time (perhaps indicating a hacking attempt).

    Since:
    1.5.0
    See Also:
    Serialized Form
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void assertThrown​(@NotNull java.lang.Runnable runnable)
      Asserts that the specified runnable throws this exception and if not throws an junit assertion failure.
      • Methods inherited from class java.lang.Throwable

        addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • LockedAccountException

        public LockedAccountException()
        Creates a new LockedAccountException.
      • LockedAccountException

        public LockedAccountException​(java.lang.String message)
        Constructs a new LockedAccountException.
        Parameters:
        message - the reason for the exception
      • LockedAccountException

        public LockedAccountException​(java.lang.Throwable cause)
        Constructs a new LockedAccountException.
        Parameters:
        cause - the underlying Throwable that caused this exception to be thrown
      • LockedAccountException

        public LockedAccountException​(java.lang.String message,
                                      java.lang.Throwable cause)
        Constructs a new LockedAccountException.
        Parameters:
        message - the reason for the exception
        cause - the underlying Throwable that caused this exception to be thrown
    • Method Detail

      • assertThrown

        public static void assertThrown​(@NotNull
                                        @NotNull java.lang.Runnable runnable)
        Asserts that the specified runnable throws this exception and if not throws an junit assertion failure.
        Parameters:
        runnable - the runnable to verify