Class TextMessageTranslator

  • All Implemented Interfaces:
    AdaptrisMessageTranslator, ComponentLifecycle, MessageTypeTranslator, MetadataHandlerContext

    public final class TextMessageTranslator
    extends MessageTypeTranslatorImp

    Translates between AdaptrisMessage and javax.jms.TextMessages. Assumes default platform encoding.

    In the adapter configuration file this class is aliased as text-message-translator which is the preferred alternative to the fully qualified classname when building your configuration.

    In the adapter configuration file this class is aliased as text-message-translator which is the preferred alternative to the fully qualified classname when building your configuration.

    • Constructor Detail

      • TextMessageTranslator

        public TextMessageTranslator()
    • Method Detail

      • translate

        public javax.jms.Message translate​(AdaptrisMessage msg)
                                    throws javax.jms.JMSException

        Translates an AdaptrisMessage into a TextMessage using the default platform character encoding.

        Parameters:
        msg - the AdaptrisMessage to translate
        Returns:
        a new TextMessage
        Throws:
        javax.jms.JMSException
      • translate

        public AdaptrisMessage translate​(javax.jms.Message msg)
                                  throws javax.jms.JMSException

        Translates a TextMessage into an AdaptrisMessage using the default platform character encoding.

        Parameters:
        msg - the TextMessage to translate
        Returns:
        an AdaptrisMessage
        Throws:
        javax.jms.JMSException