1 10 11 package org.mule.providers.jms.transformers; 12 13 import javax.jms.Message ; 14 15 import org.mule.umo.transformer.TransformerException; 16 17 32 33 public class JMSMessageToObject extends AbstractJmsTransformer 34 { 35 38 private static final long serialVersionUID = -4458860619942940372L; 39 40 public JMSMessageToObject() 41 { 42 super(); 43 registerSourceType(Message .class); 44 } 45 46 public Object doTransform(Object src, String encoding) throws TransformerException 47 { 48 try 49 { 50 if (logger.isDebugEnabled()) 51 { 52 logger.debug("Source object is " + src.getClass().getName()); 53 } 54 55 Object result = transformFromMessage((Message )src); 56 57 if (logger.isDebugEnabled()) 58 { 59 logger.debug("Resulting object is " + result.getClass().getName()); 60 } 61 62 return result; 63 } 64 catch (Exception e) 65 { 66 throw new TransformerException(this, e); 67 } 68 } 69 70 } 71 | Popular Tags |