- getAddress() - Method in interface naga.NIOAbstractSocket
-
Returns the InetSocketAddress for this socket.
- getBuffer() - Method in class naga.packetreader.DelimiterPacketReader
-
Return the currently used byte buffer.
- getBuffer() - Method in interface naga.PacketReader
-
Return the currently used byte buffer.
- getBuffer() - Method in class naga.packetreader.RawPacketReader
-
- getBuffer() - Method in class naga.packetreader.RegularPacketReader
-
Return the next buffer to use.
- getBuffer() - Method in interface naga.PacketWriter
-
The current byte buffer to write to the socket.
- getBuffer() - Method in class naga.packetwriter.RawPacketWriter
-
- getBuffer() - Method in class naga.packetwriter.RegularPacketWriter
-
- getByteBufferFromPacketSize(int, int, boolean) - Static method in class naga.NIOUtils
-
Creates a byte buffer with a given length with an encoded value,
in either big or little endian encoding (i.e.
- getBytesRead() - Method in interface naga.NIOSocket
-
Return the total number of bytes read on this socket since
it was opened.
- getBytesWritten() - Method in interface naga.NIOSocket
-
Return the total number of bytes written on this socket
since it was opened.
- getCall() - Method in interface naga.eventmachine.DelayedEvent
-
Returns the actual Runnable to be executed when this event runs.
- getIp() - Method in interface naga.NIOAbstractSocket
-
Reports the IP used by this socket.
- getMaxPacketSize() - Method in class naga.packetreader.DelimiterPacketReader
-
Get the current maximum buffer size.
- getMaxQueueSize() - Method in interface naga.NIOSocket
-
The current maximum queue size in bytes.
- getNextPacket() - Method in class naga.packetreader.DelimiterPacketReader
-
- getNextPacket() - Method in interface naga.PacketReader
-
Return the next packet constructed from the data read in the buffers.
- getNextPacket() - Method in class naga.packetreader.RawPacketReader
-
- getNextPacket() - Method in class naga.packetreader.RegularPacketReader
-
Return the next packet or null if no complete packet can be constructed.
- getNIOService() - Method in class naga.eventmachine.EventMachine
-
Returns the NIOService used by this event service.
- getObserver() - Method in class naga.eventmachine.EventMachine
-
The current ExceptionObserver used by this service.
- getPacketSizeFromByteBuffer(ByteBuffer, boolean) - Static method in class naga.NIOUtils
-
Converts a value in a header buffer encoded in either big or little endian
encoding.
- getPort() - Method in interface naga.NIOAbstractSocket
-
Returns the port in use by this socket.
- getQueue() - Method in class naga.eventmachine.EventMachine
-
Return the current event service queue.
- getQueue() - Method in class naga.NIOService
-
Returns a copy of the internal event queue.
- getQueueSize() - Method in class naga.eventmachine.EventMachine
-
Return the current queue size.
- getTime() - Method in interface naga.eventmachine.DelayedEvent
-
Returns the time when this event will execute.
- getTimeOpen() - Method in interface naga.NIOSocket
-
Return the time this socket has been open.
- getTotalAcceptedConnections() - Method in interface naga.NIOServerSocket
-
Returns the total number of accepted connections on this socket since
it opened.
- getTotalConnections() - Method in interface naga.NIOServerSocket
-
Returns the total number of connections made on this socket since
it opened.
- getTotalFailedConnections() - Method in interface naga.NIOServerSocket
-
Returns the total number of failed connections on this socket since
it opened.
- getTotalRefusedConnections() - Method in interface naga.NIOServerSocket
-
Returns the total number of refused connections on this socket since
it opened.
- getWriteQueueSize() - Method in interface naga.NIOSocket
-
This method returns the number of bytes queued for dispatch.
- naga - package naga
-
The main Naga classes.
- naga.eventmachine - package naga.eventmachine
-
An optional simple service for driving asynchronous and delayed tasks integrated with the Naga NIOService.
- naga.examples - package naga.examples
-
Various examples on how to use Naga.
- naga.exception - package naga.exception
-
Exceptions used by Naga.
- naga.packetreader - package naga.packetreader
-
Package containing various ready-to-use PacketReader
implementations.
- naga.packetwriter - package naga.packetwriter
-
Package containing various ready-to-use PacketWriter
implementations.
- newConnection(NIOSocket) - Method in interface naga.ServerSocketObserver
-
Called by the NIOService on the NIO thread when a new connection has been accepted by the socket.
- newConnection(NIOSocket) - Method in class naga.ServerSocketObserverAdapter
-
- NIOAbstractSocket - Interface in naga
-
An interface describing methods common to both NIOSocket and NIOServerSocket.
- NIOServerSocket - Interface in naga
-
Interface for the NIOServerSocket, which is
an asynchronous facade to an underlying ServerSocket.
- NIOService - Class in naga
-
This class forms the basis of the NIO handling in Naga.
- NIOService() - Constructor for class naga.NIOService
-
Create a new nio service.
- NIOSocket - Interface in naga
-
Interface for the NIOSocket, which is
an asynchronous facade to an underlying Socket.
- NIOUtils - Class in naga
-
A collection of utilites used by various classes.
- notifyExceptionThrown(Throwable) - Method in interface naga.eventmachine.ExceptionObserver
-
Notify the observer that an exception has been thrown.
- NULL - Static variable in interface naga.SocketObserver
-
A null object used as the default observer
- selectBlocking() - Method in class naga.NIOService
-
Run all waiting NIO requests, blocking indefinitely
until at least one request is handled.
- selectBlocking(long) - Method in class naga.NIOService
-
Run all waiting NIO requests, blocking until
at least one request is found, or the method has blocked
for the time given by the timeout value, whatever comes first.
- selectNonBlocking() - Method in class naga.NIOService
-
Run all waiting NIO requests, returning immediately if
no requests are found.
- serverSocketDied(Exception) - Method in interface naga.ServerSocketObserver
-
Called by the NIOService on the NIO thread when the server socket is closed.
- serverSocketDied(Exception) - Method in class naga.ServerSocketObserverAdapter
-
- ServerSocketObserver - Interface in naga
-
Implemented by an observer to a server socket.
- ServerSocketObserverAdapter - Class in naga
-
Class with null-implementations for all callbacks.
- ServerSocketObserverAdapter() - Constructor for class naga.ServerSocketObserverAdapter
-
- setConnectionAcceptor(ConnectionAcceptor) - Method in interface naga.NIOServerSocket
-
Sets the connection acceptor for this server socket.
- setMaxPacketSize(int) - Method in class naga.packetreader.DelimiterPacketReader
-
Set the new maximum packet size.
- setMaxQueueSize(int) - Method in interface naga.NIOSocket
-
Sets the maximum number of bytes allowed in the queue for this socket.
- setObserver(ExceptionObserver) - Method in class naga.eventmachine.EventMachine
-
Sets the ExceptionObserver for this service.
- setPacket(byte[]) - Method in class naga.packetwriter.RawPacketWriter
-
- setPacket(byte[]) - Method in class naga.packetwriter.RegularPacketWriter
-
- setPacket(byte[]) - Method in interface naga.PacketWriter
-
Set the next packet to write.
- setPacketReader(PacketReader) - Method in interface naga.NIOSocket
-
Sets the packet reader for this socket.
- setPacketWriter(PacketWriter) - Method in interface naga.NIOSocket
-
Sets the packet writer for this socket.
- socket() - Method in interface naga.NIOServerSocket
-
Allows access to the underlying server socket.
- socket() - Method in interface naga.NIOSocket
-
Allows access to the underlying socket.
- SocketObserver - Interface in naga
-
This interface contains the callbacks used by a NIOSocket
to inform its observer of events.
- SocketObserverAdapter - Class in naga
-
Class with null-implementation of all SocketObserver callbacks.
- SocketObserverAdapter() - Constructor for class naga.SocketObserverAdapter
-
- start() - Method in class naga.eventmachine.EventMachine
-
Causes the event machine to start running on a separate thread together with the
NIOService.
- stop() - Method in class naga.eventmachine.EventMachine
-
Stops the event machine thread.