class PayloadTransformingInterceptor extends TransformerObjectSupport implements EndpointInterceptor, InitializingBean {

	@Override
	public boolean handleResponse(MessageContext messageContext, Object endpoint) throws Exception {
		if (responseTemplates != null) {
			WebServiceMessage response = messageContext.getResponse();
			Transformer transformer = responseTemplates.newTransformer();
			transformMessage(response, transformer);
			logger.debug("Response message transformed");
		}
		return true;
	}

}