Class ClientInterceptorAdapter
java.lang.Object
org.springframework.ws.client.support.interceptor.ClientInterceptorAdapter
- All Implemented Interfaces:
ClientInterceptor
Default implementation of the
ClientInterceptor
interface, for simplified implementation of
pre-only/post-only interceptors.- Since:
- 2.2.5
- Author:
- Marten Deinum
-
Field Summary
Modifier and TypeFieldDescriptionprotected final org.apache.commons.logging.Log
Logger available to subclasses -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
afterCompletion
(MessageContext messageContext, Exception ex) Does nothing by default.boolean
handleFault
(MessageContext messageContext) Processes the incoming response fault.boolean
handleRequest
(MessageContext messageContext) Processes the outgoing request message.boolean
handleResponse
(MessageContext messageContext) Processes the incoming response message.
-
Field Details
-
logger
protected final org.apache.commons.logging.Log loggerLogger available to subclasses
-
-
Constructor Details
-
ClientInterceptorAdapter
public ClientInterceptorAdapter()
-
-
Method Details
-
handleRequest
Description copied from interface:ClientInterceptor
Processes the outgoing request message. Called after payload creation and callback invocation, but before the message is sent.- Specified by:
handleRequest
in interfaceClientInterceptor
- Parameters:
messageContext
- contains the outgoing request message- Returns:
true
to continue processing of the request interceptors;false
to indicate blocking of the request endpoint chain- Throws:
WebServiceClientException
- in case of errors- See Also:
-
handleResponse
Description copied from interface:ClientInterceptor
Processes the incoming response message. Called for non-fault response messages before payload handling in theWebServiceTemplate
.Note: Will only be called if this interceptor's
ClientInterceptor.handleRequest(org.springframework.ws.context.MessageContext)
method has successfully completed.- Specified by:
handleResponse
in interfaceClientInterceptor
- Parameters:
messageContext
- contains the outgoing request message- Returns:
true
to continue processing of the request interceptors;false
to indicate blocking of the response endpoint chain- Throws:
WebServiceClientException
- in case of errors- See Also:
-
handleFault
Description copied from interface:ClientInterceptor
Processes the incoming response fault. Called for response fault messages before payload handling in theWebServiceTemplate
.Note: Will only be called if this interceptor's
ClientInterceptor.handleRequest(org.springframework.ws.context.MessageContext)
method has successfully completed.- Specified by:
handleFault
in interfaceClientInterceptor
- Parameters:
messageContext
- contains the outgoing request message- Returns:
true
to continue processing of the request interceptors;false
to indicate blocking of the request endpoint chain- Throws:
WebServiceClientException
- in case of errors- See Also:
-
afterCompletion
public void afterCompletion(MessageContext messageContext, Exception ex) throws WebServiceClientException Does nothing by default.- Specified by:
afterCompletion
in interfaceClientInterceptor
- Parameters:
messageContext
- contains both request and response messages, the response should contains a Faultex
- exception thrown on handler execution, if any- Throws:
WebServiceClientException
- in case of errors
-