public class AuthenticationException
extends java.lang.RuntimeException
AuthenticationManager
to signal authentication failure.
Authentication failure typically occurs when one or more AuthenticationHandler
components
fail to authenticate credentials. This exception contains information about handler successes
and failures that may be used by higher-level components to determine subsequent behavior.Constructor and Description |
---|
AuthenticationException()
Instantiates a new Authentication exception.
|
AuthenticationException(java.util.Map<java.lang.String,java.lang.Throwable> handlerErrors)
Creates a new instance for the case when no handlers succeeded.
|
AuthenticationException(java.util.Map<java.lang.String,java.lang.Throwable> handlerErrors,
java.util.Map<java.lang.String,AuthenticationHandlerExecutionResult> handlerSuccesses)
Creates a new instance for the case when there are both handler successes and failures.
|
AuthenticationException(java.lang.String msg)
Creates a new instance for the case when no handlers were attempted, i.e.
|
AuthenticationException(java.lang.String message,
java.util.Map<java.lang.String,java.lang.Throwable> handlerErrors,
java.util.Map<java.lang.String,AuthenticationHandlerExecutionResult> handlerSuccesses)
Creates a new instance for the case when there are both handler successes and failures and a custom
error message is required.
|
public AuthenticationException(java.lang.String msg)
msg
- the msgpublic AuthenticationException()
public AuthenticationException(java.util.Map<java.lang.String,java.lang.Throwable> handlerErrors)
handlerErrors
- Map of handler names to errors.public AuthenticationException(java.util.Map<java.lang.String,java.lang.Throwable> handlerErrors, java.util.Map<java.lang.String,AuthenticationHandlerExecutionResult> handlerSuccesses)
handlerErrors
- Map of handler names to errors.handlerSuccesses
- Map of handler names to authentication successes.public AuthenticationException(java.lang.String message, java.util.Map<java.lang.String,java.lang.Throwable> handlerErrors, java.util.Map<java.lang.String,AuthenticationHandlerExecutionResult> handlerSuccesses)
message
- the message associated with this error.handlerErrors
- Map of handler names to errors.handlerSuccesses
- Map of handler names to authentication successes.