@Override public String getText() throws JMSException { ByteSequence content = getContent(); if (text == null && content != null) { text = decodeContent(content); setContent(null); setCompressed(false); } return text; }
@Override public String getText() throws JMSException { ByteSequence content = getContent(); if (text == null && content != null) { text = decodeContent(content); setContent(null); setCompressed(false); } return text; }
@Override public String getText() throws JMSException { ByteSequence content = getContent(); if (text == null && content != null) { text = decodeContent(content); setContent(null); setCompressed(false); } return text; }
@Override public String getText() throws JMSException { ByteSequence content = getContent(); if (text == null && content != null) { text = decodeContent(content); setContent(null); setCompressed(false); } return text; }
public String getText() throws JMSException { if (text == null && getContent() != null) { InputStream is = null; try { ByteSequence bodyAsBytes = getContent(); if (bodyAsBytes != null) { is = new ByteArrayInputStream(bodyAsBytes); if (isCompressed()) { is = new InflaterInputStream(is); } DataInputStream dataIn = new DataInputStream(is); text = MarshallingSupport.readUTF8(dataIn); dataIn.close(); setContent(null); setCompressed(false); } } catch (IOException ioe) { throw JMSExceptionSupport.create(ioe); } finally { if (is != null) { try { is.close(); } catch (IOException e) { // ignore } } } } return text; }