|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
E - exception type supported by the provider.public interface ExceptionMapper<E extends Throwable>
Contract for a provider that maps Java exceptions to Response.
Providers implementing ExceptionMapper contract must be either programmatically
registered in a JAX-RS runtime or must be annotated with
@Provider annotation to be automatically discovered
by the JAX-RS runtime during a provider scanning phase.
Provider,
Response| Method Summary | |
|---|---|
Response |
toResponse(E exception)
Map an exception to a Response. |
| Method Detail |
|---|
Response toResponse(E exception)
Response. Returning
null results in a Response.Status.NO_CONTENT
response. Throwing a runtime exception results in a
Response.Status.INTERNAL_SERVER_ERROR response.
exception - the exception to map to a response.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||