javax.ws.rs.container
Interface CompletionCallback


public interface CompletionCallback

A request processing callback that receives request processing completion events.

A completion callback is invoked when the whole request processing is over, i.e. once a response for the request has been processed and sent back to the client or in when an unmapped exception or error is being propagated to the container.

Since:
2.0
Author:
Marek Potociar

Method Summary
 void onComplete()
          A completion callback notification method that will be invoked when the request processing is finished, after a response is processed and is sent back to the client.
 void onError(Throwable throwable)
          Invoked in case an exception mapper for an exception or error thrown during request/response processing was not found and the unmapped exception or error is being propagated to the hosting I/O container.
 

Method Detail

onComplete

void onComplete()
A completion callback notification method that will be invoked when the request processing is finished, after a response is processed and is sent back to the client.


onError

void onError(Throwable throwable)
Invoked in case an exception mapper for an exception or error thrown during request/response processing was not found and the unmapped exception or error is being propagated to the hosting I/O container.

The throwable passed to the method is the actual unmapped exception thrown, during the request/response processing, i.e. not wrapped into a container-specific exception.

Parameters:
throwable - unmapped exception or error thrown during the request/response processing that is being propagated to the hosting I/O container.


Copyright © 2013. All Rights Reserved.