Overview
Package
Class
Tree
Deprecated
Index
Help
PREV NEXT
FRAMES
NO FRAMES
All Classes
A
B
C
D
E
G
H
M
N
O
P
R
S
T
U
V
W
A
accept()
- Method in interface org.khelekore.rnio.
AcceptHandler
The channel is ready for read.
accept()
- Method in class org.khelekore.rnio.impl.
Acceptor
Accept a SocketChannel.
AcceptHandler
- Interface in
org.khelekore.rnio
A handler that accepts connections
AcceptingServer
- Class in
org.khelekore.rnio.impl
A basic server for rnio.
AcceptingServer(InetAddress, int, AcceptorListener, ExecutorService, int, Long)
- Constructor for class org.khelekore.rnio.impl.
AcceptingServer
Create a new server using the parameters given.
Acceptor
- Class in
org.khelekore.rnio.impl
A standard acceptor.
Acceptor(ServerSocketChannel, NioHandler, AcceptorListener)
- Constructor for class org.khelekore.rnio.impl.
Acceptor
Create a new Acceptor that will wait for accepts on the given channel.
AcceptorListener
- Interface in
org.khelekore.rnio.impl
A listener for accepted connections.
addPendingTask(TaskIdentifier)
- Method in class org.khelekore.rnio.impl.
BasicStatisticsHolder
addPendingTask(TaskIdentifier)
- Method in interface org.khelekore.rnio.
StatisticsHolder
A new task is put in the queue, waiting to be handled.
B
BasicStatisticsHolder
- Class in
org.khelekore.rnio.impl
A holder of statistics for tasks.
BasicStatisticsHolder()
- Constructor for class org.khelekore.rnio.impl.
BasicStatisticsHolder
BufferHandler
- Interface in
org.khelekore.rnio
A ByteBuffer handler
C
CachingBufferHandler
- Class in
org.khelekore.rnio.impl
A buffer handler that re-uses returned buffers.
CachingBufferHandler()
- Constructor for class org.khelekore.rnio.impl.
CachingBufferHandler
cancel(SelectableChannel, SocketChannelHandler)
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
cancel(SelectableChannel, SocketChannelHandler)
- Method in interface org.khelekore.rnio.
NioHandler
Remove an event listener.
changeTaskStatusToFinished(TaskIdentifier, boolean, long)
- Method in class org.khelekore.rnio.impl.
BasicStatisticsHolder
changeTaskStatusToFinished(TaskIdentifier, boolean, long)
- Method in interface org.khelekore.rnio.
StatisticsHolder
A task has been completed.
changeTaskStatusToRunning(TaskIdentifier)
- Method in class org.khelekore.rnio.impl.
BasicStatisticsHolder
changeTaskStatusToRunning(TaskIdentifier)
- Method in interface org.khelekore.rnio.
StatisticsHolder
A pending task is about to be run.
channelClosed()
- Method in class org.khelekore.rnio.impl.
SimpleBlockReader
Do any cleanup that needs to be done when the channel we tried to read from was closed.
close(Closeable, Logger)
- Static method in class org.khelekore.rnio.impl.
Closer
Try to close the Closeable.
close(SelectableChannel)
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
close(SelectableChannel)
- Method in interface org.khelekore.rnio.
NioHandler
Close the given channel.
closed()
- Method in class org.khelekore.rnio.impl.
SocketHandlerBase
closed()
- Method in interface org.khelekore.rnio.
SocketChannelHandler
Signal that the channel has been closed.
Closer
- Class in
org.khelekore.rnio.impl
A helper class that can close resources without throwing exceptions.
Closer()
- Constructor for class org.khelekore.rnio.impl.
Closer
CompletionEntry
- Class in
org.khelekore.rnio.statistics
Information about a completed task.
CompletionEntry(TaskIdentifier, boolean, long)
- Constructor for class org.khelekore.rnio.statistics.
CompletionEntry
connect()
- Method in interface org.khelekore.rnio.
ConnectHandler
The channel is ready for read.
ConnectHandler
- Interface in
org.khelekore.rnio
A handler that signals that a channel is ready to connect.
connectionAccepted(SocketChannel)
- Method in interface org.khelekore.rnio.impl.
AcceptorListener
A conneciton has been accepted
D
DefaultTaskIdentifier
- Class in
org.khelekore.rnio.impl
A basic immutable task identifier
DefaultTaskIdentifier(String, String)
- Constructor for class org.khelekore.rnio.impl.
DefaultTaskIdentifier
done()
- Method in class org.khelekore.rnio.impl.
SimpleBlockSender
The default is to do nothing, override in subclasses if needed.
E
EchoClient
- Class in
org.khelekore.rnio.samples
An echo client built using rnio.
EchoClient(String, int, BufferedReader, PrintWriter)
- Constructor for class org.khelekore.rnio.samples.
EchoClient
EchoServer
- Class in
org.khelekore.rnio.samples
An echo server built using rnio.
EchoServer(int)
- Constructor for class org.khelekore.rnio.samples.
EchoServer
end()
- Method in interface org.khelekore.rnio.
SelectorVisitor
Indicates that all selectors have been visited
G
getBuffer()
- Method in interface org.khelekore.rnio.
BufferHandler
Get a byte buffer of reasonable size, the buffer will have been cleared.
getBuffer()
- Method in class org.khelekore.rnio.impl.
CachingBufferHandler
getBuffer()
- Method in class org.khelekore.rnio.impl.
SimpleBlockSender
Get the buffer we are sending data from.
getByteBuffer()
- Method in class org.khelekore.rnio.impl.
SimpleBlockReader
Called before a read attempt is made.
getDefaultTimeout()
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
getDefaultTimeout()
- Method in interface org.khelekore.rnio.
NioHandler
Get the default timeout time for an operations started at this point in time.
getDescription()
- Method in class org.khelekore.rnio.impl.
Acceptor
Returns the class name and the channel we are using.
getDescription()
- Method in class org.khelekore.rnio.impl.
DefaultTaskIdentifier
getDescription()
- Method in class org.khelekore.rnio.impl.
SocketHandlerBase
Returns the class name.
getDescription()
- Method in interface org.khelekore.rnio.
SocketChannelHandler
Get a string description.
getDescription()
- Method in interface org.khelekore.rnio.
TaskIdentifier
Get the description of this task.
getFailures()
- Method in class org.khelekore.rnio.statistics.
TotalTimeSpent
Get the number of failed jobs
getGroupId()
- Method in class org.khelekore.rnio.impl.
DefaultTaskIdentifier
getGroupId()
- Method in interface org.khelekore.rnio.
TaskIdentifier
Get the group id.
getLatest()
- Method in class org.khelekore.rnio.impl.
BasicStatisticsHolder
getLatest()
- Method in interface org.khelekore.rnio.
StatisticsHolder
Get information about the most recent completed tasks
getLongest()
- Method in class org.khelekore.rnio.impl.
BasicStatisticsHolder
getLongest()
- Method in interface org.khelekore.rnio.
StatisticsHolder
Get information about the longest running task.
getNioHandler()
- Method in class org.khelekore.rnio.impl.
AcceptingServer
Get the NioHandler in use by this server.
getPendingTasks()
- Method in class org.khelekore.rnio.impl.
BasicStatisticsHolder
getPendingTasks()
- Method in interface org.khelekore.rnio.
StatisticsHolder
Get information about the currently pending tasks.
getRunningTasks()
- Method in class org.khelekore.rnio.impl.
BasicStatisticsHolder
getRunningTasks()
- Method in interface org.khelekore.rnio.
StatisticsHolder
Get information about the currently running tasks.
getSuccessful()
- Method in class org.khelekore.rnio.statistics.
TotalTimeSpent
Get the number of successfully completed jobs
getTimeout()
- Method in class org.khelekore.rnio.impl.
SocketHandlerBase
Will return null to indicate no timeout on accepts.
getTimeout()
- Method in interface org.khelekore.rnio.
SocketChannelHandler
Get the timeout time in millis.
getTimingStatistics()
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
getTimingStatistics()
- Method in interface org.khelekore.rnio.
NioHandler
Get the timing information for the thread tasks.
getTotalMillis()
- Method in class org.khelekore.rnio.statistics.
TotalTimeSpent
Get the total time spent doing this kind of task
getTotalTimeSpent()
- Method in class org.khelekore.rnio.impl.
BasicStatisticsHolder
getTotalTimeSpent()
- Method in interface org.khelekore.rnio.
StatisticsHolder
Get the total time spent for each task.
growBuffer(ByteBuffer)
- Method in interface org.khelekore.rnio.
BufferHandler
Get a larger buffer with the same contents as buffer, this will also return buffer to the pool.
growBuffer(ByteBuffer)
- Method in class org.khelekore.rnio.impl.
CachingBufferHandler
H
handleBufferRead(ByteBuffer)
- Method in class org.khelekore.rnio.impl.
SimpleBlockReader
Handle the buffer content.
handleIOException(IOException)
- Method in class org.khelekore.rnio.impl.
SimpleBlockReader
Handle the exception, default is to log it and to close the channel.
handleIOException(IOException)
- Method in class org.khelekore.rnio.impl.
SimpleBlockSender
Handle the exception, default is to log it and to close the channel.
M
main(String[])
- Static method in class org.khelekore.rnio.samples.
EchoClient
main(String[])
- Static method in class org.khelekore.rnio.samples.
EchoServer
MultiSelectorNioHandler
- Class in
org.khelekore.rnio.impl
An implementation of NioHandler that runs several selector threads.
MultiSelectorNioHandler(ExecutorService, StatisticsHolder, int, Long)
- Constructor for class org.khelekore.rnio.impl.
MultiSelectorNioHandler
Create a new MultiSelectorNioHandler that runs background tasks on the given executor and has a specified number of selectors.
N
nioHandler
- Variable in class org.khelekore.rnio.impl.
SocketHandlerBase
NioHandler
- Interface in
org.khelekore.rnio
A handler of nio based events.
O
org.khelekore.rnio
- package org.khelekore.rnio
The basic interfaces for rnio.
org.khelekore.rnio.impl
- package org.khelekore.rnio.impl
The classes that actually implement rnio.
org.khelekore.rnio.samples
- package org.khelekore.rnio.samples
Examples of using rnio.
org.khelekore.rnio.statistics
- package org.khelekore.rnio.statistics
Statistics information about rnio.
P
putBuffer(ByteBuffer)
- Method in interface org.khelekore.rnio.
BufferHandler
Return a buffer.
putBuffer(ByteBuffer)
- Method in class org.khelekore.rnio.impl.
CachingBufferHandler
putByteBuffer(ByteBuffer)
- Method in class org.khelekore.rnio.impl.
SimpleBlockReader
Return the ByteBuffer, this method will be called when read gets EOF or no data.
R
read()
- Method in class org.khelekore.rnio.impl.
SimpleBlockReader
Try to read data from the channel.
read()
- Method in interface org.khelekore.rnio.
ReadHandler
The channel is ready for read.
ReadHandler
- Interface in
org.khelekore.rnio
A handler that signals that data is ready to be read.
register()
- Method in class org.khelekore.rnio.impl.
Acceptor
Register OP_ACCEPT with the selector.
register()
- Method in class org.khelekore.rnio.impl.
SimpleBlockReader
Wait for the channel to become read ready.
register()
- Method in class org.khelekore.rnio.impl.
SimpleBlockSender
Register writeWait on the nioHandler
runThreadTask(Runnable, TaskIdentifier)
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
runThreadTask(Runnable, TaskIdentifier)
- Method in interface org.khelekore.rnio.
NioHandler
Run a task in a background thread.
S
sc
- Variable in class org.khelekore.rnio.impl.
SocketHandlerBase
selector(Selector)
- Method in interface org.khelekore.rnio.
SelectorVisitor
Visit one selector.
SelectorVisitor
- Interface in
org.khelekore.rnio
A visitor of the selectors used by a NioHandler.
shutdown()
- Method in class org.khelekore.rnio.impl.
AcceptingServer
Shutdown the NioHandler.
shutdown()
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
shutdown()
- Method in interface org.khelekore.rnio.
NioHandler
Shutdown this task runner.
shutdown()
- Method in class org.khelekore.rnio.samples.
EchoClient
SimpleBlockReader
- Class in
org.khelekore.rnio.impl
A reader of data.
SimpleBlockReader(SocketChannel, NioHandler, Long)
- Constructor for class org.khelekore.rnio.impl.
SimpleBlockReader
Create a new block reader.
SimpleBlockSender
- Class in
org.khelekore.rnio.impl
A simple sender of data.
SimpleBlockSender(SocketChannel, NioHandler, ByteBuffer, Long)
- Constructor for class org.khelekore.rnio.impl.
SimpleBlockSender
SocketChannelHandler
- Interface in
org.khelekore.rnio
A handler for socket operations.
SocketHandlerBase
<
T
extends
SelectableChannel
> - Class in
org.khelekore.rnio.impl
A socket handler that never times out and always runs on the selector thread.
SocketHandlerBase(T, NioHandler, Long)
- Constructor for class org.khelekore.rnio.impl.
SocketHandlerBase
start()
- Method in class org.khelekore.rnio.impl.
AcceptingServer
Start the NioHandler and register to accept new socket connections.
start()
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
start()
- Method in interface org.khelekore.rnio.
NioHandler
Start handling operations.
start()
- Method in class org.khelekore.rnio.samples.
EchoClient
start()
- Method in class org.khelekore.rnio.samples.
EchoServer
StatisticsHolder
- Interface in
org.khelekore.rnio
A holder of statistics for tasks.
T
TaskIdentifier
- Interface in
org.khelekore.rnio
Identifier for a long and/or slow operation.
ti
- Variable in class org.khelekore.rnio.statistics.
CompletionEntry
The identifier of the task that has been completed.
timeout
- Variable in class org.khelekore.rnio.impl.
SocketHandlerBase
timeout()
- Method in class org.khelekore.rnio.impl.
SocketHandlerBase
Handle timeouts.
timeout()
- Method in interface org.khelekore.rnio.
SocketChannelHandler
Signal that the select operation timed out.
timeSpent
- Variable in class org.khelekore.rnio.statistics.
CompletionEntry
The number of millis spent on the task.
TotalTimeSpent
- Class in
org.khelekore.rnio.statistics
Information about total time spent on a group of tasks.
TotalTimeSpent()
- Constructor for class org.khelekore.rnio.statistics.
TotalTimeSpent
U
update(CompletionEntry)
- Method in class org.khelekore.rnio.statistics.
TotalTimeSpent
Update this information with data from the newly completed task.
useSeparateThread()
- Method in class org.khelekore.rnio.impl.
SocketHandlerBase
Will always run on the selector thread so return false.
useSeparateThread()
- Method in interface org.khelekore.rnio.
SocketChannelHandler
Check if this handler needs to run in a separate thread.
V
visitSelectors(SelectorVisitor)
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
visitSelectors(SelectorVisitor)
- Method in interface org.khelekore.rnio.
NioHandler
Visit all the selectors.
W
waitForAccept(SelectableChannel, AcceptHandler)
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
waitForAccept(SelectableChannel, AcceptHandler)
- Method in interface org.khelekore.rnio.
NioHandler
Install an event listener for accent events.
waitForConnect(SelectableChannel, ConnectHandler)
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
waitForConnect(SelectableChannel, ConnectHandler)
- Method in interface org.khelekore.rnio.
NioHandler
Install an event listener for connect events.
waitForRead(SelectableChannel, ReadHandler)
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
waitForRead(SelectableChannel, ReadHandler)
- Method in interface org.khelekore.rnio.
NioHandler
Install an event listener for read events.
waitForWrite(SelectableChannel, WriteHandler)
- Method in class org.khelekore.rnio.impl.
MultiSelectorNioHandler
waitForWrite(SelectableChannel, WriteHandler)
- Method in interface org.khelekore.rnio.
NioHandler
Install an event listener for write events.
wasOk
- Variable in class org.khelekore.rnio.statistics.
CompletionEntry
The status of the completed job.
write()
- Method in class org.khelekore.rnio.impl.
SimpleBlockSender
write()
- Method in interface org.khelekore.rnio.
WriteHandler
The channel is ready for read.
WriteHandler
- Interface in
org.khelekore.rnio
A handler that signals that data is ready to be written.
A
B
C
D
E
G
H
M
N
O
P
R
S
T
U
V
W
Overview
Package
Class
Tree
Deprecated
Index
Help
PREV NEXT
FRAMES
NO FRAMES
All Classes