-
- All Superinterfaces:
Conduit,SinkConduit
- All Known Implementing Classes:
AbstractMessageSinkConduit,FramingMessageSinkConduit,SaslUnwrappingConduit,SaslWrappingConduit,SynchronizedMessageSinkConduit
public interface MessageSinkConduit extends SinkConduit
A message sink conduit.- Author:
- David M. Lloyd
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleansend(java.nio.ByteBuffer src)Send a complete message.booleansend(java.nio.ByteBuffer[] srcs, int offs, int len)Send a complete message.booleansendFinal(java.nio.ByteBuffer src)Send a complete message.booleansendFinal(java.nio.ByteBuffer[] srcs, int offs, int len)Send a complete message.-
Methods inherited from interface org.xnio.conduits.SinkConduit
awaitWritable, awaitWritable, flush, getWriteThread, isWriteResumed, isWriteShutdown, resumeWrites, setWriteReadyHandler, suspendWrites, terminateWrites, truncateWrites, wakeupWrites
-
-
-
-
Method Detail
-
send
boolean send(java.nio.ByteBuffer src) throws java.io.IOExceptionSend a complete message.- Parameters:
src- the message to send- Returns:
- the result of the send operation;
trueif the message was sent, orfalseif it would block - Throws:
java.io.IOException- if an I/O error occurs
-
send
boolean send(java.nio.ByteBuffer[] srcs, int offs, int len) throws java.io.IOExceptionSend a complete message.- Parameters:
srcs- the buffers holding the message to sendoffs- the offset into the buffer array of the first bufferlen- the number of buffers that contain data to send- Returns:
- the result of the send operation;
trueif the message was sent, orfalseif it would block - Throws:
java.io.IOException- if an I/O error occurs
-
sendFinal
boolean sendFinal(java.nio.ByteBuffer src) throws java.io.IOExceptionSend a complete message. If the message is successfully sent then the sink will have its writes terminated.- Parameters:
src- the message to send- Returns:
- the result of the send operation;
trueif the message was sent, orfalseif it would block - Throws:
java.io.IOException- if an I/O error occurs
-
sendFinal
boolean sendFinal(java.nio.ByteBuffer[] srcs, int offs, int len) throws java.io.IOExceptionSend a complete message. If the message is successfully sent then the sink will have its writes terminated.- Parameters:
srcs- the buffers holding the message to sendoffs- the offset into the buffer array of the first bufferlen- the number of buffers that contain data to send- Returns:
- the result of the send operation;
trueif the message was sent, orfalseif it would block - Throws:
java.io.IOException- if an I/O error occurs
-
-