org.jboss.resteasy.client.core
Interface ClientErrorInterceptor


public interface ClientErrorInterceptor

ClientErrorInterceptor provides a hook into the proxy ClientResponse request lifecycle. If a Client Proxy method is called, resulting in a client exception, and the proxy return type is not Response or ClientResponse, registered interceptors will be given a chance to process the response manually, or throw a new exception. If all interceptors successfully return, RestEasy will re-throw the original encountered exception.

Author:
Lincoln Baxter, III

Method Summary
 void handle(ClientResponse<?> response)
          Attempt to handle the current ClientResponse.
 

Method Detail

handle

void handle(ClientResponse<?> response)
            throws RuntimeException
Attempt to handle the current ClientResponse. If this method returns successfully, the next registered ClientErrorInterceptor will attempt to handle the ClientResponse. If this method throws an exception, no further interceptors will be processed.

Throws:
RuntimeException - RestEasy will abort request processing if any exception is thrown from this method.


Copyright © 2012. All Rights Reserved.