public interface UnauthorizedHandler
| Modifier and Type | Method and Description |
|---|---|
default RuntimeException |
buildException(String prefix,
String realm)
This method allows overriding the exception thrown from an
AuthFilter instance. |
default javax.ws.rs.core.Response |
buildResponse(String prefix,
String realm) |
@Nullable default javax.ws.rs.core.Response buildResponse(String prefix, String realm)
default RuntimeException buildException(String prefix, String realm)
AuthFilter instance.
This provides the possibility to catch auth exceptions in a custom ExceptionMapper.
To process the exception in a custom ExceptionMapper, the response entity MUST be empty
when using a subclass of WebApplicationException.
Else the ExceptionMapper won't get invoked.
The default implementation of this method creates a WebApplicationException containing the response built
in buildResponse(String, String).Copyright © 2011. All rights reserved.