org.springframework.flex.core
Interface ResourceHandlingMessageInterceptor

All Superinterfaces:
MessageInterceptor

public interface ResourceHandlingMessageInterceptor
extends MessageInterceptor

Extension of the MessageInterceptor interface that adds an additional callback to be invoked after standard message processing is completed. This callback will be invoked even when an Exception is thrown by the current request's Endpoint. This gives the interceptor a chance to clean up any resources that may have been created for the current request.

Since:
1.0.2
Author:
Jeremy Grelle

Method Summary
 void afterCompletion(MessageProcessingContext context, flex.messaging.messages.Message inputMessage, flex.messaging.messages.Message outputMessage, java.lang.Exception ex)
          Callback to be invoked when message processing is complete, giving the interceptor a chance to clean up resources.
 
Methods inherited from interface org.springframework.flex.core.MessageInterceptor
postProcess, preProcess
 

Method Detail

afterCompletion

void afterCompletion(MessageProcessingContext context,
                     flex.messaging.messages.Message inputMessage,
                     flex.messaging.messages.Message outputMessage,
                     java.lang.Exception ex)
Callback to be invoked when message processing is complete, giving the interceptor a chance to clean up resources.

Parameters:
context - - the MessageProcessingContext for the current request
inputMessage - - the incoming AMF message
outputMessage - - the outgoing AMF message, null in the case of an exception thrown by the Endpoint
ex - - exception thrown by the Endpoint, null in the case of successful processing