Interface JmsStreamMessageFacade
-
- All Superinterfaces:
JmsMessageFacade,TraceableMessage
- All Known Implementing Classes:
AmqpJmsStreamMessageFacade
public interface JmsStreamMessageFacade extends JmsMessageFacade
Interface for a Message Facade that wraps a stream or list based provider message instance. The interface provides the basic entry points into a stream style message where primitive values are read and written as opaque objects.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description JmsStreamMessageFacadecopy()Create a new instance and perform a deep copy of this object's contents.booleanhasNext()java.lang.Objectpeek()Peek and return the next element in the stream.voidpop()Pops the next element in the stream.voidput(java.lang.Object value)Writes a new object value to the stream.voidreset()Reset the position of the stream to the beginning.-
Methods inherited from interface org.apache.qpid.jms.message.facade.JmsMessageFacade
clearBody, clearProperties, encodeMessage, getCorrelationId, getCorrelationIdBytes, getDeliveryCount, getDeliveryTime, getDestination, getExpiration, getGroupId, getGroupSequence, getMessageId, getPriority, getProperty, getPropertyNames, getProviderMessageIdObject, getRedeliveryCount, getReplyTo, getTimestamp, getType, getUserId, getUserIdBytes, hasBody, isDeliveryTimeTransmitted, isPersistent, isRedelivered, onDispatch, onSend, propertyExists, setCorrelationId, setCorrelationIdBytes, setDeliveryCount, setDeliveryTime, setDestination, setExpiration, setGroupId, setGroupSequence, setMessageId, setPersistent, setPriority, setProperty, setProviderMessageIdObject, setRedelivered, setRedeliveryCount, setReplyTo, setTimestamp, setType, setUserId, setUserIdBytes
-
Methods inherited from interface org.apache.qpid.jms.tracing.TraceableMessage
filterTracingAnnotations, getTracingAnnotation, getTracingContext, removeTracingAnnotation, removeTracingContext, setTracingAnnotation, setTracingContext
-
-
-
-
Method Detail
-
copy
JmsStreamMessageFacade copy() throws jakarta.jms.JMSException
Description copied from interface:JmsMessageFacadeCreate a new instance and perform a deep copy of this object's contents.- Specified by:
copyin interfaceJmsMessageFacade- Returns:
- a deep copy of this Message Facade including a complete copy of the byte contents of the wrapped message.
- Throws:
jakarta.jms.JMSException- if an error occurs while copying the message.
-
hasNext
boolean hasNext()
- Returns:
- true if the stream contains another element beyond the current.
-
peek
java.lang.Object peek() throws jakarta.jms.MessageEOFExceptionPeek and return the next element in the stream. If the stream has been fully read then this method should throw a MessageEOFException. Multiple calls to peek should return the same element.- Returns:
- the next value in the stream without removing it.
- Throws:
jakarta.jms.MessageEOFException- if end of message stream has been reached.
-
pop
void pop() throws jakarta.jms.MessageEOFException
Pops the next element in the stream.- Throws:
jakarta.jms.MessageEOFException- if end of message stream has been reached.
-
put
void put(java.lang.Object value)
Writes a new object value to the stream. If the value provided is a byte[] its entry then it is assumed that it was copied by the caller and its value will not be altered by the provider.- Parameters:
value- The object value to be written to the stream.
-
reset
void reset()
Reset the position of the stream to the beginning.
-
-