Top Description Constructors Methods
org.xnio.conduits

public abstract Class AbstractMessageSinkConduit<D extends MessageSinkConduit>

extends AbstractSinkConduit<D extends MessageSinkConduit>
implements MessageSinkConduit
Class Inheritance
All Implemented Interfaces
org.xnio.conduits.MessageSinkConduit, org.xnio.conduits.SinkConduit, org.xnio.conduits.Conduit
Known Direct Subclasses
org.xnio.sasl.SaslUnwrappingConduit, org.xnio.sasl.SaslWrappingConduit
Imports
java.io.IOException, java.nio.ByteBuffer

An abstract base class for filtering message sink conduits.
Author
David M. Lloyd

Constructor Summary

AccessConstructor and Description
protected
AbstractMessageSinkConduit(final D
the delegate conduit to set
next
)

Construct a new instance.

Method Summary

Modifier and TypeMethod and Description
public boolean
send(final ByteBuffer
the message to send
src
)

Implements org.xnio.conduits.MessageSinkConduit.send.

Send a complete message.

public boolean
send(final ByteBuffer[]
the buffers holding the message to send
srcs
,
final int
the offset into the buffer array of the first buffer
offs
,
final int
the number of buffers that contain data to send
len
)

Implements org.xnio.conduits.MessageSinkConduit.send.

Send a complete message.

public boolean
sendFinal(ByteBuffer[]
the buffers holding the message to send
srcs
,
int
the offset into the buffer array of the first buffer
offs
,
int
the number of buffers that contain data to send
len
)

Implements org.xnio.conduits.MessageSinkConduit.sendFinal.

Send a complete message.

public boolean
sendFinal(ByteBuffer
the message to send
src
)

Implements org.xnio.conduits.MessageSinkConduit.sendFinal.

Send a complete message.

Inherited from org.xnio.conduits.AbstractSinkConduit:
awaitWritableawaitWritableflushgetWriteThreadisWriteResumedisWriteShutdownresumeWritessetWriteReadyHandlersuspendWritesterminateWritestruncateWriteswakeupWrites

Constructor Detail

AbstractMessageSinkConduitback to summary
protected AbstractMessageSinkConduit(final D next)

Construct a new instance.

Parameters
next:D

the delegate conduit to set

Method Detail

sendback to summary
public boolean send(final ByteBuffer src) throws IOException

Implements org.xnio.conduits.MessageSinkConduit.send.

Doc from org.xnio.conduits.MessageSinkConduit.send.

Send a complete message.

Parameters
src:ByteBuffer

the message to send

Returns:boolean

the result of the send operation; true if the message was sent, or false if it would block

Exceptions
IOException:
if an I/O error occurs
sendback to summary
public boolean send(final ByteBuffer[] srcs, final int offs, final int len) throws IOException

Implements org.xnio.conduits.MessageSinkConduit.send.

Doc from org.xnio.conduits.MessageSinkConduit.send.

Send a complete message.

Parameters
srcs:ByteBuffer[]

the buffers holding the message to send

offs:int

the offset into the buffer array of the first buffer

len:int

the number of buffers that contain data to send

Returns:boolean

the result of the send operation; true if the message was sent, or false if it would block

Exceptions
IOException:
if an I/O error occurs
sendFinalback to summary
public boolean sendFinal(ByteBuffer[] srcs, int offs, int len) throws IOException

Implements org.xnio.conduits.MessageSinkConduit.sendFinal.

Doc from org.xnio.conduits.MessageSinkConduit.sendFinal.

Send a complete message. If the message is successfully sent then the sink will have its writes terminated.

Parameters
srcs:ByteBuffer[]

the buffers holding the message to send

offs:int

the offset into the buffer array of the first buffer

len:int

the number of buffers that contain data to send

Returns:boolean

the result of the send operation; true if the message was sent, or false if it would block

Annotations
@Override
Exceptions
IOException:
if an I/O error occurs
sendFinalback to summary
public boolean sendFinal(ByteBuffer src) throws IOException

Implements org.xnio.conduits.MessageSinkConduit.sendFinal.

Doc from org.xnio.conduits.MessageSinkConduit.sendFinal.

Send a complete message. If the message is successfully sent then the sink will have its writes terminated.

Parameters
src:ByteBuffer

the message to send

Returns:boolean

the result of the send operation; true if the message was sent, or false if it would block

Annotations
@Override
Exceptions
IOException:
if an I/O error occurs