com.ibm.passwordrules
Class InvalidPasswordException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by com.ibm.itim.exception.ITIMException
              extended by com.ibm.passwordrules.InvalidPasswordException
All Implemented Interfaces:
java.io.Serializable

public class InvalidPasswordException
extends ITIMException

Objects of this class are thrown when a password violates one of the rules.

See Also:
Serialized Form

Constructor Summary
InvalidPasswordException(Rule ruleViolated)
          Construct an invalid password exception with the rule that was violated.
InvalidPasswordException(Rule ruleViolated, java.lang.String reason)
          Construct an invalid password exception with the rule that was violated and the reason for the violation.
 
Method Summary
 java.lang.String getReason()
          Gets the reason that the password violated the given rule.
 Rule getRuleViolated()
          Returns the rule that was violated to generate this exception.
 
Methods inherited from class com.ibm.itim.exception.ITIMException
getLocalizedMessage, getMessage, getMessage, getMessageId, getThrowable, getTokens, normalize, printStackTrace, printStackTrace, printStackTrace, toXML
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getStackTrace, initCause, setStackTrace, toString
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

InvalidPasswordException

public InvalidPasswordException(Rule ruleViolated)
Construct an invalid password exception with the rule that was violated.

Parameters:
ruleViolated - The rule the password violates.

InvalidPasswordException

public InvalidPasswordException(Rule ruleViolated,
                                java.lang.String reason)
Construct an invalid password exception with the rule that was violated and the reason for the violation.

Parameters:
ruleViolated - The rule the password violates.
reason - Reason for the violation.
Method Detail

getRuleViolated

public Rule getRuleViolated()
Returns the rule that was violated to generate this exception.

Returns:
violated rule

getReason

public java.lang.String getReason()
Gets the reason that the password violated the given rule. May be an empty string indicating that no reason was given.

Returns:
reason for violation. Constant representing a error message key in a property file.


IBM Security Identity Manager 6.0.0
© Copyright International Business Machines Corporation 2007, 2012. All rights reserved. US Government Users Restricited Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.