1 7 package org.jboss.jms; 8 9 import javax.jms.JMSException ; 10 import javax.jms.TextMessage ; 11 12 16 public class TextMessageImpl extends MessageImpl implements TextMessage  17 { 18 19 TextMessageImpl() 20 { 21 this.type = MessageImpl.TEXT_MESSAGE_NAME; 22 } 23 24 public TextMessageImpl(String text) 25 { 26 this.type = MessageImpl.TEXT_MESSAGE_NAME; 27 this.body = text; 28 } 29 30 public String getText() 31 { 32 return (String ) this.body; 33 } 34 35 public void setText(String text) throws JMSException  36 { 37 this.throwExceptionIfReadOnly(); 38 super.body = text; 39 } 40 } | Popular Tags |