Spring Web Services Framework

org.springframework.ws.transport.jms
Class JmsMessageReceiver

java.lang.Object
  extended by org.springframework.ws.transport.support.WebServiceMessageReceiverObjectSupport
      extended by org.springframework.ws.transport.support.SimpleWebServiceMessageReceiverObjectSupport
          extended by org.springframework.ws.transport.jms.JmsMessageReceiver
All Implemented Interfaces:
InitializingBean
Direct Known Subclasses:
WebServiceMessageListener

public class JmsMessageReceiver
extends SimpleWebServiceMessageReceiverObjectSupport

Convenience base class for JMS server-side transport objects. Contains a WebServiceMessageReceiver, and has methods for handling incoming JMS BytesMessage and TextMessage requests. Also contains a textMessageEncoding property, which determines the encoding used to read from and write to TextMessages. This property defaults to UTF-8.

Used by WebServiceMessageListener and WebServiceMessageDrivenBean.

Since:
1.5.0
Author:
Arjen Poutsma

Field Summary
static String DEFAULT_TEXT_MESSAGE_ENCODING
          Default encoding used to read from and write to TextMessage messages.
 
Fields inherited from class org.springframework.ws.transport.support.WebServiceMessageReceiverObjectSupport
logger
 
Constructor Summary
JmsMessageReceiver()
           
 
Method Summary
protected  void handleMessage(Message request, Session session)
          Handles an incoming message.
 void setPostProcessor(MessagePostProcessor postProcessor)
          Sets the optional MessagePostProcessor to further modify outgoing messages after the XML contents has been set.
 void setTextMessageEncoding(String textMessageEncoding)
          Sets the encoding used to read from and write to TextMessage messages.
 
Methods inherited from class org.springframework.ws.transport.support.SimpleWebServiceMessageReceiverObjectSupport
afterPropertiesSet, getMessageReceiver, handleConnection, setMessageReceiver
 
Methods inherited from class org.springframework.ws.transport.support.WebServiceMessageReceiverObjectSupport
getMessageFactory, handleConnection, setMessageFactory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_TEXT_MESSAGE_ENCODING

public static final String DEFAULT_TEXT_MESSAGE_ENCODING
Default encoding used to read from and write to TextMessage messages.

See Also:
Constant Field Values
Constructor Detail

JmsMessageReceiver

public JmsMessageReceiver()
Method Detail

setTextMessageEncoding

public void setTextMessageEncoding(String textMessageEncoding)
Sets the encoding used to read from and write to TextMessage messages. Defaults to UTF-8.


setPostProcessor

public void setPostProcessor(MessagePostProcessor postProcessor)
Sets the optional MessagePostProcessor to further modify outgoing messages after the XML contents has been set.


handleMessage

protected final void handleMessage(Message request,
                                   Session session)
                            throws Exception
Handles an incoming message. Uses the given session to create a response message.

Parameters:
request - the incoming message
session - the JMS session used to create a response
Throws:
IllegalArgumentException - when request is not a BytesMessage
Exception

Spring Web Services Framework

Copyright © 2005-2013 The Spring Web Services Framework. All Rights Reserved.