Enum PasswordStatus

    • Enum Constant Detail

      • NEVER_CREATED

        public static final PasswordStatus NEVER_CREATED
        The password has never been created for the user
      • PENDING

        public static final PasswordStatus PENDING
        The password was manually allowed (by admins) for the user to generate it, but it was not yet generated (never used for manual passwords)
      • ACTIVE

        public static final PasswordStatus ACTIVE
        The password is active and valid
      • DISABLED

        public static final PasswordStatus DISABLED
        The password has been manually disabled
      • RESET

        public static final PasswordStatus RESET
        The password has been reset
      • TEMPORARILY_BLOCKED

        public static final PasswordStatus TEMPORARILY_BLOCKED
        The password is temporarily blocked by exceeding the maximum attempts (depends on the max attempts action defined in the password type: temporarily blocked). Not persisted, but calculated.
      • INDEFINITELY_BLOCKED

        public static final PasswordStatus INDEFINITELY_BLOCKED
        The password is blocked by exceeding the maximum attempts until it is manually unblocked. (depends on the max attempts action defined in the password type: indefinitely blocked).
      • EXPIRED

        public static final PasswordStatus EXPIRED
        The password is expired. Not persisted, but calculated.
      • OLD

        public static final PasswordStatus OLD
        A password which is not in use anymore, but stays there for the sake of knowing whether a password as already used in past. Should never be returned to clients, as whenever an old password exists, a new password (with a status other than old) should exist.
    • Method Detail

      • values

        public static PasswordStatus[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (PasswordStatus c : PasswordStatus.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static PasswordStatus valueOf​(String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        IllegalArgumentException - if this enum type has no constant with the specified name
        NullPointerException - if the argument is null
      • allowForgotPassword

        public boolean allowForgotPassword​(boolean requiresAdminAuthorization)
        Indicates whether the forgot password option can be used in this status.
        Parameters:
        requiresAdminAuthorization - For generated passwords, manual admin authorization might be needed. In this case, the NEVER_CREATED status returns false.