Index

A B C D E F G H I L M N O P R S T V W 
All Classes and Interfaces|All Packages|Constant Field Values|Serialized Form

A

AbstractNestedChannel<I extends SelectableChannel & ReadableByteChannel,O extends SelectableChannel & WritableByteChannel> - Class in org.dellroad.muxable.simple
A straightforward implementation of most of the NestedChannel interface.
AbstractNestedChannel(MuxableChannel<I, O>, I, O, ByteBuffer) - Constructor for class org.dellroad.muxable.simple.AbstractNestedChannel
Constructor.
allocateLocalChannelId() - Method in class org.dellroad.muxable.simple.ChannelIds
Allocate a new local channel ID.
allocateRemoteChannelId(long) - Method in class org.dellroad.muxable.simple.ChannelIds
Allocate a remote channel ID, if channelId represents the next available remote channel ID to be allocated.

B

BIDIRECTIONAL - Enum constant in enum class org.dellroad.muxable.Directions
There should be both input and output channels.
buildLoggingSupport() - Method in class org.dellroad.muxable.simple.SimpleMuxableChannel
 

C

ChannelIds - Class in org.dellroad.muxable.simple
Tracks channel ID's for the SimpleMuxableChannel framing protocol.
ChannelIds() - Constructor for class org.dellroad.muxable.simple.ChannelIds
Deafult constructor.
ChannelIds(Logger, String) - Constructor for class org.dellroad.muxable.simple.ChannelIds
Constructor.
close() - Method in interface org.dellroad.muxable.MuxableChannel
Close this instance.
close() - Method in interface org.dellroad.muxable.NestedChannel
Close this nested channel.
close() - Method in class org.dellroad.muxable.simple.SimpleMuxableChannel
 
close() - Method in class org.dellroad.muxable.simple.SimpleNestedChannel
 
closeAndCatch(Closeable) - Method in class org.dellroad.muxable.simple.SimpleMuxableChannel
 
closeConnection() - Method in class org.dellroad.muxable.simple.ProtocolWriter
Close the entire connection.
closeNestedChannel(long) - Method in class org.dellroad.muxable.simple.ProtocolWriter
Close an open nested channel.
CURRENT_PROTOCOL_VERSION - Static variable in class org.dellroad.muxable.simple.ProtocolConstants
Current protocol version.

D

debug(String, Object...) - Method in class org.dellroad.muxable.simple.LoggingSupport
Log at debug level (if enabled).
describeFlags(int) - Static method in class org.dellroad.muxable.simple.OutputQueue
Return a debug description of the given flags.
Directions - Enum Class in org.dellroad.muxable
Used to specifify which of input and/or output directions are desired when creating a new nested channel.

E

enqueue(ByteBuffer) - Method in class org.dellroad.muxable.simple.OutputQueue
Add the given data to queue.
error(String, Object...) - Method in class org.dellroad.muxable.simple.LoggingSupport
Log at error level (if enabled).

F

FLAG_DIRECTION_INPUT - Static variable in class org.dellroad.muxable.simple.ProtocolConstants
Flag that indicates a new nested channel should support communicating from the peer to the originator.
FLAG_DIRECTION_OUTPUT - Static variable in class org.dellroad.muxable.simple.ProtocolConstants
Flag that indicates a new nested channel should support communicating from the originator to the peer.
formatLog(String, Object...) - Method in class org.dellroad.muxable.simple.LoggingSupport
Format a log message.
freeChannelId(long, boolean) - Method in class org.dellroad.muxable.simple.ChannelIds
Deallocate (i.e., mark as closed) a channel ID previously allocated by allocateLocalChannelId() or allocateRemoteChannelId().

G

getInput() - Method in interface org.dellroad.muxable.NestedChannel
Get the input channel, if any.
getInput() - Method in class org.dellroad.muxable.simple.AbstractNestedChannel
 
getNestedChannelRequests() - Method in interface org.dellroad.muxable.MuxableChannel
Access the queue of incoming NestedChannels initiated from the remote side.
getNestedChannelRequests() - Method in class org.dellroad.muxable.simple.SimpleMuxableChannel
 
getNextLocalChannelId() - Method in class org.dellroad.muxable.simple.ChannelIds
Get the next available local channel ID.
getNextRemoteChannelId() - Method in class org.dellroad.muxable.simple.ChannelIds
Get the next available remote channel ID.
getOffset() - Method in class org.dellroad.muxable.simple.ProtocolReader
Get the current stream offset.
getOffset() - Method in exception org.dellroad.muxable.simple.ProtocolViolationException
Get the absolute position in the input stream at which the protocol violation was detected.
getOpenChannelIds() - Method in class org.dellroad.muxable.simple.ChannelIds
Get all open channel ID's.
getOutput() - Method in interface org.dellroad.muxable.NestedChannel
Get the output channel, if any.
getOutput() - Method in class org.dellroad.muxable.simple.AbstractNestedChannel
 
getParent() - Method in interface org.dellroad.muxable.NestedChannel
Get the parent MuxableChannel.
getParent() - Method in class org.dellroad.muxable.simple.AbstractNestedChannel
 
getParent() - Method in class org.dellroad.muxable.simple.SimpleNestedChannel
 
getRequestData() - Method in interface org.dellroad.muxable.NestedChannel
Get the request data associated with this request.
getRequestData() - Method in class org.dellroad.muxable.simple.AbstractNestedChannel
 
getTotalBytesQueued() - Method in class org.dellroad.muxable.simple.OutputQueue
Get the total number of bytes of data currently enqueued.

H

hasInput() - Method in enum class org.dellroad.muxable.Directions
Determine whether this instance includes an input channel.
hasOutput() - Method in enum class org.dellroad.muxable.Directions
Determine whether this instance includes an output channel.

I

info(String, Object...) - Method in class org.dellroad.muxable.simple.LoggingSupport
Log at info level (if enabled).
input - Variable in class org.dellroad.muxable.simple.AbstractNestedChannel
 
input(ByteBuffer) - Method in class org.dellroad.muxable.simple.ProtocolReader
Input new data from the remote side into the protocol state machine.
INPUT_ONLY - Enum constant in enum class org.dellroad.muxable.Directions
There should be an input channel but no output channel.
isChannelOpen(long) - Method in class org.dellroad.muxable.simple.ChannelIds
Determine whether the specified channel is still open.
isEmpty() - Method in class org.dellroad.muxable.simple.OutputQueue
Determine if this queue is empty.
isFull() - Method in class org.dellroad.muxable.simple.OutputQueue
Determine if this queue is full.
isOpen() - Method in class org.dellroad.muxable.simple.SimpleMuxableChannel
 

L

log - Variable in class org.dellroad.muxable.simple.LoggingSupport
 
LoggingSupport - Class in org.dellroad.muxable.simple
Debug logging support class.
LoggingSupport() - Constructor for class org.dellroad.muxable.simple.LoggingSupport
Default constructor.
LoggingSupport(Object) - Constructor for class org.dellroad.muxable.simple.LoggingSupport
Constructor.
LoggingSupport(Logger, String) - Constructor for class org.dellroad.muxable.simple.LoggingSupport
Primary constructor.
logPrefix - Variable in class org.dellroad.muxable.simple.LoggingSupport
 

M

MuxableChannel<I extends SelectableChannel & ReadableByteChannel,O extends SelectableChannel & WritableByteChannel> - Interface in org.dellroad.muxable
A single channel supporting parallel nested byte-oriented channels operating independently.

N

NestedChannel<I extends SelectableChannel & ReadableByteChannel,O extends SelectableChannel & WritableByteChannel> - Interface in org.dellroad.muxable
Represents one nested I/O channel within a MuxableChannel.
nestedChannelClosed(long) - Method in interface org.dellroad.muxable.simple.ProtocolReader.InputHandler
An existing nested channel has been closed by the remote side.
nestedChannelData(long, ByteBuffer) - Method in interface org.dellroad.muxable.simple.ProtocolReader.InputHandler
Data has been received on a nested channel.
nestedChannelRequest(long, ByteBuffer, Directions) - Method in interface org.dellroad.muxable.simple.ProtocolReader.InputHandler
A new nested channel request has been received.
newNestedChannel(ByteBuffer) - Method in interface org.dellroad.muxable.MuxableChannel
Create a pair of nested input and output channels scoped to this instance.
newNestedChannel(ByteBuffer) - Method in class org.dellroad.muxable.simple.SimpleMuxableChannel
 
newNestedChannel(ByteBuffer, Directions) - Method in interface org.dellroad.muxable.MuxableChannel
Create a new nested channel, or pair of nested channels, scoped to this instance.
newNestedChannel(ByteBuffer, Directions) - Method in class org.dellroad.muxable.simple.SimpleMuxableChannel
 
NOW_EMPTY - Static variable in class org.dellroad.muxable.simple.OutputQueue
Flag bit in the flags returned by enqueue() and writeTo().
NOW_FULL - Static variable in class org.dellroad.muxable.simple.OutputQueue
Flag bit in the flags returned by enqueue() and writeTo().

O

openNestedChannel(ByteBuffer, Directions) - Method in class org.dellroad.muxable.simple.ProtocolWriter
Open a new local nested channel.
org.dellroad.muxable - package org.dellroad.muxable
A Java library for multiplexing multiple byte-oriented channels over a single parent channel.
org.dellroad.muxable.simple - package org.dellroad.muxable.simple
Simple implementation(s) of the MuxableChannel interface.
output - Variable in class org.dellroad.muxable.simple.AbstractNestedChannel
 
OUTPUT_ONLY - Enum constant in enum class org.dellroad.muxable.Directions
There should be an output channel but no input channel.
OutputQueue - Class in org.dellroad.muxable.simple
A output queue of bytes stored in ByteBuffers.
OutputQueue(long) - Constructor for class org.dellroad.muxable.simple.OutputQueue
Constructor.

P

parent - Variable in class org.dellroad.muxable.simple.AbstractNestedChannel
 
PROTOCOL_COOKIE - Static variable in class org.dellroad.muxable.simple.ProtocolConstants
Magic value that verifies remote side is speaking our language.
ProtocolConstants - Class in org.dellroad.muxable.simple
Constants used in the SimpleMuxableChannel framing protocol.
ProtocolReader - Class in org.dellroad.muxable.simple
Input state machine for the SimpleMuxableChannel framing protocol.
ProtocolReader(ChannelIds, ProtocolReader.InputHandler) - Constructor for class org.dellroad.muxable.simple.ProtocolReader
Constructor.
ProtocolReader(Logger, String, ChannelIds, ProtocolReader.InputHandler) - Constructor for class org.dellroad.muxable.simple.ProtocolReader
Constructor.
ProtocolReader.InputHandler - Interface in org.dellroad.muxable.simple
Callback interface invoked by a ProtocolReader.
ProtocolViolationException - Exception in org.dellroad.muxable.simple
Exception thrown when a SimpleMuxableChannel framing protocol violation is detected.
ProtocolViolationException(long, String) - Constructor for exception org.dellroad.muxable.simple.ProtocolViolationException
Constructor.
ProtocolViolationException(long, String, Throwable) - Constructor for exception org.dellroad.muxable.simple.ProtocolViolationException
Constructor.
ProtocolWriter - Class in org.dellroad.muxable.simple
Output state machine for the SimpleMuxableChannel framing protocol.
ProtocolWriter(ChannelIds, ProtocolWriter.OutputHandler) - Constructor for class org.dellroad.muxable.simple.ProtocolWriter
Constructor.
ProtocolWriter(Logger, String, ChannelIds, ProtocolWriter.OutputHandler) - Constructor for class org.dellroad.muxable.simple.ProtocolWriter
Constructor.
ProtocolWriter.OutputHandler - Interface in org.dellroad.muxable.simple
 

R

requestData - Variable in class org.dellroad.muxable.simple.AbstractNestedChannel
 

S

sendOutput(ByteBuffer) - Method in interface org.dellroad.muxable.simple.ProtocolWriter.OutputHandler
Send raw data to the remote peer.
simpleLogPrefix(Object) - Static method in class org.dellroad.muxable.simple.LoggingSupport
Build a simple log message prefix based on the given object.
SimpleMuxableChannel - Class in org.dellroad.muxable.simple
An implementation of the MuxableChannel interface that multiplexes nested channels over a single underlying ByteChannel (or ReadableByteChannel, WritableByteChannel pair) using a simple framing protocol.
SimpleMuxableChannel(C) - Constructor for class org.dellroad.muxable.simple.SimpleMuxableChannel
Constructor taking a single, bi-directional ByteChannel.
SimpleMuxableChannel(I, O) - Constructor for class org.dellroad.muxable.simple.SimpleMuxableChannel
Constructor inferring the SelectorProvider to use.
SimpleMuxableChannel(SelectorProvider, I, O) - Constructor for class org.dellroad.muxable.simple.SimpleMuxableChannel
Primary constructor.
SimpleNestedChannel - Class in org.dellroad.muxable.simple
NestedChannel implementation used by SimpleMuxableChannel.
start() - Method in class org.dellroad.muxable.simple.SimpleMuxableChannel
 
stop() - Method in class org.dellroad.muxable.simple.SimpleMuxableChannel
 

T

toString() - Method in class org.dellroad.muxable.simple.AbstractNestedChannel
 
toString(ByteBuffer, int) - Static method in class org.dellroad.muxable.simple.LoggingSupport
Produce a debug-loggable String version of the given ByteBuffer.
trace(String, Object...) - Method in class org.dellroad.muxable.simple.LoggingSupport
Log at trace level (if enabled).

V

validateLocalChannelId(long) - Method in class org.dellroad.muxable.simple.ChannelIds
Validate a local channel ID.
validateRemoteChannelId(long) - Method in class org.dellroad.muxable.simple.ChannelIds
Validate a remote channel ID.
valueOf(String) - Static method in enum class org.dellroad.muxable.Directions
Returns the enum constant of this class with the specified name.
values() - Static method in enum class org.dellroad.muxable.Directions
Returns an array containing the constants of this enum class, in the order they are declared.

W

warn(String, Object...) - Method in class org.dellroad.muxable.simple.LoggingSupport
Log at warn level (if enabled).
WAS_EMPTY - Static variable in class org.dellroad.muxable.simple.OutputQueue
Flag bit in the flags returned by enqueue() and writeTo().
WAS_FULL - Static variable in class org.dellroad.muxable.simple.OutputQueue
Flag bit in the flags returned by enqueue() and writeTo().
writeNestedChannel(long, ByteBuffer) - Method in class org.dellroad.muxable.simple.ProtocolWriter
Send data on the nested channel with the specified channel ID.
writeTo(WritableByteChannel) - Method in class org.dellroad.muxable.simple.OutputQueue
Write as much data as possible to the specified output channel.
A B C D E F G H I L M N O P R S T V W 
All Classes and Interfaces|All Packages|Constant Field Values|Serialized Form