Class MappableExceptionWrapperInterceptor
java.lang.Object
org.glassfish.jersey.server.internal.MappableExceptionWrapperInterceptor
- All Implemented Interfaces:
javax.ws.rs.ext.ReaderInterceptor
,javax.ws.rs.ext.WriterInterceptor
@Priority(10)
@Singleton
public class MappableExceptionWrapperInterceptor
extends Object
implements javax.ws.rs.ext.ReaderInterceptor, javax.ws.rs.ext.WriterInterceptor
Interceptor that wraps specific exceptions types thrown by wrapped interceptors and by message
body readers and writers into a mappable exception.
It must have the lowest priority in order to wrap all other interceptors.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
Binder registering theException Wrapper Interceptor
(used on the client side). -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaroundReadFrom
(javax.ws.rs.ext.ReaderInterceptorContext context) void
aroundWriteTo
(javax.ws.rs.ext.WriterInterceptorContext context)
-
Constructor Details
-
MappableExceptionWrapperInterceptor
public MappableExceptionWrapperInterceptor()
-
-
Method Details
-
aroundReadFrom
public Object aroundReadFrom(javax.ws.rs.ext.ReaderInterceptorContext context) throws IOException, javax.ws.rs.WebApplicationException - Specified by:
aroundReadFrom
in interfacejavax.ws.rs.ext.ReaderInterceptor
- Throws:
IOException
javax.ws.rs.WebApplicationException
-
aroundWriteTo
public void aroundWriteTo(javax.ws.rs.ext.WriterInterceptorContext context) throws IOException, javax.ws.rs.WebApplicationException - Specified by:
aroundWriteTo
in interfacejavax.ws.rs.ext.WriterInterceptor
- Throws:
IOException
javax.ws.rs.WebApplicationException
-