Package | Description |
---|---|
org.snf4j.core |
Provides interfaces and classes implementing the core functionalities of the
API.
|
org.snf4j.core.future |
Provides interfaces and classes used by the API to implement futures.
|
org.snf4j.core.session |
Provides classes and interfaces used for session handling.
|
org.snf4j.websocket |
Provides main interfaces and classes implementing the functionalities of the
Web Socket protocol.
|
Modifier and Type | Method and Description |
---|---|
IFuture<Void> |
SelectorLoop.register(DatagramChannel channel,
DatagramSession session)
Registers a datagram-oriented channel with this selector loop.
|
IFuture<Void> |
SelectorLoop.register(DatagramChannel channel,
IDatagramHandler handler)
Registers a datagram-oriented channel with this selector loop.
|
static IFuture<Void> |
SctpRegistrator.register(SelectorLoop loop,
com.sun.nio.sctp.SctpChannel channel,
ISctpHandler handler)
Registers an SCTP channel with the specified selector loop.
|
static IFuture<Void> |
SctpRegistrator.register(SelectorLoop loop,
com.sun.nio.sctp.SctpChannel channel,
SctpSession session)
Registers an SCTP channel with the specified selector loop.
|
static IFuture<Void> |
SctpRegistrator.register(SelectorLoop loop,
com.sun.nio.sctp.SctpMultiChannel channel,
ISctpHandler handler)
Registers an SCTP multi channel with the specified selector loop.
|
static IFuture<Void> |
SctpRegistrator.register(SelectorLoop loop,
com.sun.nio.sctp.SctpMultiChannel channel,
SctpMultiSession session)
Registers an SCTP multi channel with the specified selector loop.
|
static IFuture<Void> |
SctpRegistrator.register(SelectorLoop loop,
com.sun.nio.sctp.SctpServerChannel channel,
ISctpSessionFactory factory)
Registers a listening SCTP channel with the specified selector loop.
|
IFuture<Void> |
SelectorLoop.register(ServerSocketChannel channel,
IStreamSessionFactory factory)
Registers a listening stream-oriented channel with this selector loop.
|
IFuture<Void> |
SelectorLoop.register(SocketChannel channel,
IStreamHandler handler)
Registers a stream-oriented channel with this selector loop.
|
IFuture<Void> |
SelectorLoop.register(SocketChannel channel,
StreamSession session)
Registers a stream-oriented channel with this selector loop.
|
IFuture<Void> |
EngineDatagramSession.send(SocketAddress remoteAddress,
byte[] datagram) |
IFuture<Void> |
DatagramSession.send(SocketAddress remoteAddress,
byte[] datagram) |
IFuture<Void> |
EngineDatagramSession.send(SocketAddress remoteAddress,
byte[] datagram,
int offset,
int length) |
IFuture<Void> |
DatagramSession.send(SocketAddress remoteAddress,
byte[] datagram,
int offset,
int length) |
IFuture<Void> |
EngineDatagramSession.send(SocketAddress remoteAddress,
ByteBuffer datagram) |
IFuture<Void> |
DatagramSession.send(SocketAddress remoteAddress,
ByteBuffer datagram) |
IFuture<Void> |
EngineDatagramSession.send(SocketAddress remoteAddress,
ByteBuffer datagram,
int length) |
IFuture<Void> |
DatagramSession.send(SocketAddress remoteAddress,
ByteBuffer datagram,
int length) |
IFuture<Void> |
EngineDatagramSession.send(SocketAddress remoteAddress,
IByteBufferHolder datagram) |
IFuture<Void> |
DatagramSession.send(SocketAddress remoteAddress,
IByteBufferHolder datagram) |
IFuture<Void> |
EngineDatagramSession.send(SocketAddress remoteAddress,
Object msg) |
IFuture<Void> |
DatagramSession.send(SocketAddress remoteAddress,
Object msg) |
IFuture<Void> |
SctpMultiSession.shutdown(com.sun.nio.sctp.Association association) |
IFuture<Void> |
SctpMultiSession.write(byte[] msg) |
IFuture<Void> |
StreamSession.write(byte[] data) |
IFuture<Void> |
EngineStreamSession.write(byte[] data) |
IFuture<Void> |
EngineDatagramSession.write(byte[] datagram) |
IFuture<Void> |
DatagramSession.write(byte[] datagram) |
IFuture<Void> |
SctpMultiSession.write(byte[] msg,
int offset,
int length) |
IFuture<Void> |
StreamSession.write(byte[] data,
int offset,
int length) |
IFuture<Void> |
EngineStreamSession.write(byte[] data,
int offset,
int length) |
IFuture<Void> |
EngineDatagramSession.write(byte[] datagram,
int offset,
int length) |
IFuture<Void> |
DatagramSession.write(byte[] datagram,
int offset,
int length) |
IFuture<Void> |
SctpMultiSession.write(ByteBuffer msg) |
IFuture<Void> |
StreamSession.write(ByteBuffer data) |
IFuture<Void> |
EngineStreamSession.write(ByteBuffer data) |
IFuture<Void> |
EngineDatagramSession.write(ByteBuffer datagram) |
IFuture<Void> |
DatagramSession.write(ByteBuffer datagram) |
IFuture<Void> |
SctpMultiSession.write(ByteBuffer msg,
int length) |
IFuture<Void> |
StreamSession.write(ByteBuffer data,
int length) |
IFuture<Void> |
EngineStreamSession.write(ByteBuffer data,
int length) |
IFuture<Void> |
EngineDatagramSession.write(ByteBuffer datagram,
int length) |
IFuture<Void> |
DatagramSession.write(ByteBuffer datagram,
int length) |
IFuture<Void> |
StreamSession.write(IByteBufferHolder holder) |
IFuture<Void> |
EngineStreamSession.write(IByteBufferHolder holder) |
IFuture<Void> |
EngineDatagramSession.write(IByteBufferHolder datagram) |
IFuture<Void> |
DatagramSession.write(IByteBufferHolder datagram) |
IFuture<Void> |
SctpMultiSession.write(Object msg) |
IFuture<Void> |
StreamSession.write(Object msg) |
IFuture<Void> |
EngineDatagramSession.write(Object msg) |
IFuture<Void> |
DatagramSession.write(Object msg) |
Modifier and Type | Interface and Description |
---|---|
interface |
IAbortableFuture<V>
A future that can be aborted (cancelled or failed) at any time.
|
interface |
IDelegatingFuture<V>
A future which state and result can be represented by other delegate future.
|
interface |
ITwoThresholdFuture<V>
An
interface that represents a future which state is determined by two
thresholds. |
Modifier and Type | Class and Description |
---|---|
class |
AbstractFuture<V>
Base implementation of the
IFuture interface. |
class |
CancelledFuture<V>
A cancelled future
|
class |
CompletedFuture<V>
A completed future.
|
class |
FailedFuture<V>
A failed future
|
class |
RegisterFuture<V>
A future that represents the result of the asynchronous register methods of selector loops.
|
class |
SuccessfulFuture<V>
A successful future
|
class |
TaskFuture<V>
A future that represents the result of a asynchronous task.
|
Modifier and Type | Method and Description |
---|---|
IFuture<V> |
IFuture.await()
Waits for this future to be completed.
|
IFuture<V> |
CompletedFuture.await()
Returns immediately
|
IFuture<V> |
IFuture.await(long timeoutMillis)
Waits for this future to be completed within the specified time limit.
|
IFuture<V> |
CompletedFuture.await(long timeoutMillis)
Returns immediately
|
IFuture<V> |
IFuture.await(long timeout,
TimeUnit unit)
Waits for this future to be completed within the specified time limit.
|
IFuture<V> |
CompletedFuture.await(long timeout,
TimeUnit unit)
Returns immediately
|
IFuture<V> |
IFuture.awaitUninterruptibly()
Waits for this future to be completed without interruption.
|
IFuture<V> |
CompletedFuture.awaitUninterruptibly()
Returns immediately
|
IFuture<V> |
IFuture.awaitUninterruptibly(long timeoutMillis)
Waits for this future to be completed within the specified time limit
without interruption.
|
IFuture<V> |
CompletedFuture.awaitUninterruptibly(long timeoutMillis)
Returns immediately
|
IFuture<V> |
IFuture.awaitUninterruptibly(long timeout,
TimeUnit unit)
Waits for this future to be completed within the specified time limit
without interruption.
|
IFuture<V> |
CompletedFuture.awaitUninterruptibly(long timeout,
TimeUnit unit)
Returns immediately
|
IFuture<Void> |
SessionFuturesController.getCancelledFuture()
Returns a cancelled future.
|
IFuture<Void> |
SessionFuturesController.getCloseFuture()
Returns the future that can be use to wait for the completion of the
session's closing phase.
|
IFuture<Void> |
SessionFuturesController.getCreateFuture()
Returns the future that can be use to wait for the completion of the
session's creation phase.
|
IFuture<Void> |
SessionFuturesController.getEndFuture()
Returns the future that can be use to wait for the completion of the
session's ending phase.
|
IFuture<Void> |
SessionFuturesController.getFailedFuture(Throwable cause)
Returns a failed future with the specified cause.
|
IFuture<Void> |
SessionFuturesController.getOpenFuture()
Returns the future that can be use to wait for the completion of the
session's opening phase.
|
IFuture<Void> |
SessionFuturesController.getReadyFuture()
Returns the future that can be use to wait for the completion of the
session's ready phase.
|
IFuture<Void> |
SessionFuturesController.getSuccessfulFuture()
Returns a successful future.
|
IFuture<Void> |
SessionFuturesController.getWriteFuture(long expectedSize)
Returns a future that can be used to wait for the completion of a write
operation.
|
IFuture<V> |
IFuture.sync()
Waits for this future to be completed, and throws an exception that wraps
the cause of the failure if this future failed.
|
IFuture<V> |
CompletedFuture.sync()
Returns immediately
|
IFuture<V> |
IFuture.sync(long timeoutMillis)
Waits for this future to be completed within the specified time limit,
and throws an exception that wraps the cause of the failure if this
future failed.
|
IFuture<V> |
CompletedFuture.sync(long timeoutMillis)
Returns immediately
|
IFuture<V> |
IFuture.sync(long timeout,
TimeUnit unit)
Waits for this future to be completed within the specified time limit,
and throws an exception that wraps the cause of the failure if this
future failed.
|
IFuture<V> |
CompletedFuture.sync(long timeout,
TimeUnit unit)
Returns immediately
|
IFuture<V> |
IFuture.syncUninterruptibly()
Waits for this future to be completed without interruption, and throws an
exception that wraps the cause of the failure if this future failed.
|
IFuture<V> |
CompletedFuture.syncUninterruptibly()
Returns immediately
|
IFuture<V> |
IFuture.syncUninterruptibly(long timeoutMillis)
Waits for this future to be completed within the specified time limit
without interruption, and throws an exception that wraps the cause of the
failure if this future failed.
|
IFuture<V> |
CompletedFuture.syncUninterruptibly(long timeoutMillis)
Returns immediately
|
IFuture<V> |
IFuture.syncUninterruptibly(long timeout,
TimeUnit unit)
Waits for this future to be completed within the specified time limit
without interruption, and throws an exception that wraps the cause of the
failure if this future failed.
|
IFuture<V> |
CompletedFuture.syncUninterruptibly(long timeout,
TimeUnit unit)
Returns immediately
|
Modifier and Type | Method and Description |
---|---|
void |
IDelegatingFuture.setDelegate(IFuture<V> delegate)
Sets the delegate future which state and result will represent this
future.
|
Modifier and Type | Method and Description |
---|---|
IFuture<Void> |
ISctpSession.bindAddress(InetAddress address)
Adds the given address to the bound addresses for the SCTP channel's socket
associated with this session
|
IFuture<Void> |
ISession.execute(Runnable task)
Executes a task in the selector-loop's thread this session is registered
with.
|
IFuture<Void> |
ISession.getCloseFuture()
Gets the future that can be use to wait for the completion of the closing
phase.
|
IFuture<Void> |
ISession.getCreateFuture()
Gets the future that can be use to wait for the completion of the
creation phase.
|
IFuture<Void> |
ISession.getEndFuture()
Gets the future that can be use to wait for the completion of the ending
phase.
|
IFuture<Void> |
ISession.getOpenFuture()
Gets the future that can be use to wait for the completion of the opening
phase.
|
IFuture<Void> |
ISession.getReadyFuture()
Gets the future that can be use to wait for the completion of the ready
phase.
|
IFuture<Void> |
IDatagramSession.send(SocketAddress remoteAddress,
byte[] datagram)
Sends a
datagram.length byte datagram from the specified
byte array to a remote end via the datagram-oriented channel associated
with this session. |
IFuture<Void> |
IDatagramSession.send(SocketAddress remoteAddress,
byte[] datagram,
int offset,
int length)
Sends a
length byte datagram from the specified byte array
to a remote end via the datagram-oriented channel associated with this
session. |
IFuture<Void> |
IDatagramSession.send(SocketAddress remoteAddress,
ByteBuffer datagram)
Sends a
datagram.remaining() byte datagram from the specified byte
buffer to a remote end via the datagram-oriented channel associated with this
session. |
IFuture<Void> |
IDatagramSession.send(SocketAddress remoteAddress,
ByteBuffer datagram,
int length)
Sends a
length byte datagram from the specified byte buffer
to a remote end via the datagram-oriented channel associated with this
session. |
IFuture<Void> |
IDatagramSession.send(SocketAddress remoteAddress,
IByteBufferHolder datagram)
Sends a
datagram.remaining() byte datagram from the specified byte
buffer holder to a remote end via the datagram-oriented channel associated with
this session. |
IFuture<Void> |
IDatagramSession.send(SocketAddress remoteAddress,
Object msg)
Sends a message to a remote end via the datagram-oriented channel
associated with this session.
|
IFuture<Void> |
ISctpMultiSession.shutdown(com.sun.nio.sctp.Association association)
Shutdown an association without closing this session.
|
IFuture<Void> |
ISctpSession.unbindAddress(InetAddress address)
Removes the given address from the bound addresses for the SCTP channel's
socket associated with this session
|
IFuture<Void> |
ISctpSession.write(byte[] msg)
Writes a message from the specified byte array to the SCTP channel that is
associated with this session.
|
IFuture<Void> |
ISctpMultiSession.write(byte[] msg)
Writes a message from the specified byte array to the SCTP channel that is
associated with this session.
|
IFuture<Void> |
IStreamSession.write(byte[] data)
Writes
data.length bytes from the specified byte array
to the stream-oriented channel associated with this session. |
IFuture<Void> |
IDatagramSession.write(byte[] datagram)
Writes a
datagram.length byte datagram from the specified
byte array to the datagram-oriented channel associated with this session. |
IFuture<Void> |
ISctpSession.write(byte[] msg,
ImmutableSctpMessageInfo msgInfo)
Writes a message from the specified byte array to the SCTP channel that is
associated with this session.
|
IFuture<Void> |
ISctpSession.write(byte[] msg,
int offset,
int length)
Writes a message of given length from the specified byte array to the SCTP
channel that is associated with this session.
|
IFuture<Void> |
ISctpMultiSession.write(byte[] msg,
int offset,
int length)
Writes a message of given length from the specified byte array to the SCTP
channel that is associated with this session.
|
IFuture<Void> |
IStreamSession.write(byte[] data,
int offset,
int length)
Writes
length bytes from the specified byte array
to the stream-oriented channel associated with this session. |
IFuture<Void> |
IDatagramSession.write(byte[] datagram,
int offset,
int length)
Writes a
length byte datagram from the specified byte array
to the datagram-oriented channel associated with this session. |
IFuture<Void> |
ISctpSession.write(byte[] msg,
int offset,
int length,
ImmutableSctpMessageInfo msgInfo)
Writes a message of given length from the specified byte array to the SCTP
channel that is associated with this session.
|
IFuture<Void> |
ISctpSession.write(ByteBuffer msg)
Writes a message from the specified byte buffer to the SCTP channel that is
associated with this session.
|
IFuture<Void> |
ISctpMultiSession.write(ByteBuffer msg)
Writes a message from the specified byte buffer to the SCTP channel that is
associated with this session.
|
IFuture<Void> |
IStreamSession.write(ByteBuffer data)
Writes
data.remaining() bytes from the specified
byte buffer to the stream-oriented channel associated with
this session. |
IFuture<Void> |
IDatagramSession.write(ByteBuffer datagram)
Writes a
datagram.remaining() byte datagram from the specified byte buffer
to the datagram-oriented channel associated with this session. |
IFuture<Void> |
ISctpSession.write(ByteBuffer msg,
ImmutableSctpMessageInfo msgInfo)
Writes a message from the specified byte buffer to the SCTP channel that is
associated with this session.
|
IFuture<Void> |
ISctpSession.write(ByteBuffer msg,
int length)
Writes a message of given length from the specified byte buffer to the SCTP
channel that is associated with this session.
|
IFuture<Void> |
ISctpMultiSession.write(ByteBuffer msg,
int length)
Writes a message of given length from the specified byte buffer to the SCTP
channel that is associated with this session.
|
IFuture<Void> |
IStreamSession.write(ByteBuffer data,
int length)
Writes
length bytes from the specified byte buffer
to the stream-oriented channel associated with this session. |
IFuture<Void> |
IDatagramSession.write(ByteBuffer datagram,
int length)
Writes a
length byte datagram from the specified byte buffer
to the datagram-oriented channel associated with this session. |
IFuture<Void> |
ISctpSession.write(ByteBuffer msg,
int length,
ImmutableSctpMessageInfo msgInfo)
Writes a message of given length from the specified byte buffer to the SCTP
channel that is associated with this session.
|
IFuture<Void> |
IStreamSession.write(IByteBufferHolder holder)
Writes
holder.remaining() bytes from the specified byte buffer
holder to the stream-oriented channel associated with this session. |
IFuture<Void> |
IDatagramSession.write(IByteBufferHolder datagram)
Writes a
datagram.remaining() byte datagram from the specified byte buffer
holder to the datagram-oriented channel associated with this session. |
IFuture<Void> |
ISctpSession.write(Object msg)
Writes a message to the SCTP channel that is associated with this session.
|
IFuture<Void> |
ISctpMultiSession.write(Object msg)
Writes a message to the SCTP channel that is associated with this session.
|
IFuture<Void> |
IStreamSession.write(Object msg)
Writes a message to the stream-oriented channel associated with this
session.
|
IFuture<Void> |
IDatagramSession.write(Object msg)
Writes a message to the datagram-oriented channel associated with this session.
|
IFuture<Void> |
ISctpSession.write(Object msg,
ImmutableSctpMessageInfo msgInfo)
Writes a message to the SCTP channel that is associated with this session.
|
Modifier and Type | Method and Description |
---|---|
IFuture<Void> |
WebSocketSession.getReadyFuture()
Gets the future that can be use to wait for the completion of the Web Socket
handshake phase.
|
IFuture<Void> |
SSLWebSocketSession.getReadyFuture()
Gets the future that can be use to wait for the completion of the Web Socket
handshake phase.
|
Copyright © 2017–2022 SNF4J.ORG. All rights reserved.