A simple message converter that can handle ITextMessages, IBytesMessages, IMapMessages, and IObjectMessages. Used as default by NmsTemplate, for ConvertAndSend and ReceiveAndConvert operations.

Converts a String to a NMS ITextMessage, a byte array to a NMS IBytesMessage, a Map to a NMS IMapMessage, and a Serializable object to a NMS IObjectMessage (or vice versa).

Inheritance: IMessageConverter
Ejemplo n.º 1
0
 /// <summary> Initialize the default implementations for the template's strategies:
 /// DynamicDestinationResolver and SimpleMessageConverter.
 /// </summary>
 protected virtual void InitDefaultStrategies()
 {
     MessageConverter = new SimpleMessageConverter();
 }
 public void Setup()
 {
     mocks = new MockRepository();
     session = mocks.StrictMock<ISession>();
     converter = new SimpleMessageConverter();
 }
 public void Setup()
 {
     mocks = new MockRepository();
     session = (ISession) mocks.CreateMock(typeof (ISession));
     converter = new SimpleMessageConverter();
 }