public class MessageBodyWriter<T> extends java.lang.Object implements SinkWriter<T,org.apache.activemq.artemis.api.core.client.ClientMessage>
MessageBodyReader| Constructor and Description |
|---|
MessageBodyWriter(SinkWriter<T,java.io.OutputStream> serializer)
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
write(org.apache.activemq.artemis.api.core.client.ClientMessage sink,
T body)
Writes a value to a data sink.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waituncheckedWritepublic MessageBodyWriter(SinkWriter<T,java.io.OutputStream> serializer)
serializer - the serializer to use.java.lang.NullPointerException - if the argument is null.public void write(org.apache.activemq.artemis.api.core.client.ClientMessage sink,
T body)
throws java.lang.Exception
SinkWriterwrite in interface SinkWriter<T,org.apache.activemq.artemis.api.core.client.ClientMessage>sink - where to write the value to.body - the data to write.java.lang.NullPointerException - if any of the arguments is null.java.lang.Exception - if the data could not be written to the sink.