|
||||||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | |||||||||
See:
Description
| Interface Summary | |
|---|---|
| AsynchronousByteChannel | A channel that can read and write bytes asynchronously. |
| ChannelPoolMXBean | The management interface for a channel pool. |
| CompletionHandler<R,A> | A handler for consuming the result of an asynchronous operation. |
| IoFuture<R,A> | A Future representing the result of an asynchronous I/O
operation. |
| ManagedChannelFactory | An object with a management interface to pools of channels. |
| MulticastChannel | A network channel that supports Internet Protocol (IP) multicasting. |
| NetworkChannel | A channel to a network socket. |
| ProtocolFamily | Represents a family of communication protocols. |
| SocketOption | A socket option associated with a socket. |
| ThreadPoolFactory | An object that creates thread pools on demand. |
| Class Summary | |
|---|---|
| AsynchronousChannel | A channel that supports asynchronous operations. |
| AsynchronousChannelGroup | An organization of asynchronous channels for the purpose of resource sharing. |
| AsynchronousDatagramChannel | An asynchronous channel for datagram-oriented sockets. |
| AsynchronousServerSocketChannel | An asynchronous channel for stream-oriented listening sockets. |
| AsynchronousSocketChannel | An asynchronous channel for stream-oriented connecting sockets. |
| Channels | Utility methods for channels and streams. |
| MembershipKey | A token representing the membership of an Internet Protocol (IP) multicast group. |
| Enum Summary | |
|---|---|
| ShutdownType | A typesafe enumeration used when shutting down a connection on a stream-oriented connecting socket. |
| StandardProtocolFamily | Defines the standard family of communication protocols. |
| StandardSocketOption | Defines the standard socket options. |
| Exception Summary | |
|---|---|
| AbortedByTimeoutException | Checked exception received by a thread when a timeout elapses before an asynchronous I/O operation completes. |
| AcceptPendingException | Unchecked exception thrown when an attempt is made to initiate an accept operation on a channel and a previous accept operation has not completed. |
| AlreadyBoundException | Unchecked exception thrown when an attempt is made to bind the socket of a network oriented channel that is already bound. |
| ClosedAsynchronousChannelException | Unchecked exception thrown when an attempt is made to initiate an asynchronous operation on an asynchronous channel that is closed. |
| IllegalChannelStateException | Unchecked exception received when a channel operation is attempted that has previously completed due to a timeout. |
| ReadPendingException | Unchecked exception thrown when an attempt is made to initiate a read operation on a channel and a previous read operation has not completed. |
| ShutdownChannelGroupException | Unchecked exception thrown when an attempt is made to construct a channel in a group that is shutdown. |
| WritePendingException | Unchecked exception thrown when an attempt is made to initiate a write operation on a channel and a previous write operation has not completed. |
Defines asynchronous channels that are connected to a stream-oriented connecting or listening socket, or a datagram-oriented socket.
Asynchronous I/O
Description
AsynchronousChannelA channel capable of asynchronous operations AsynchronousFileChannel[[NOT IMPLEMENTED]] An asynchronous channel for reading, writing, and manipulating a file AsynchronousSocketChannelAn asynchronous channel to a stream-oriented connecting socket AsynchronousServerSocketChannelAn asynchronous channel to a stream-oriented listening socket AsynchronousDatagramChannelAn asynchronous channel to a datagram-oriented socket CompletionHandlerA handler for consuming the result of an asynchronous operation IoFutureA Future representing the result of an asynchronous I/O operation AsynchronousChannelGroupA grouping of asynchronous channels for the purpose of resource sharing
Asynchronous I/O is provided by asynchronous channels, I/O futures, and completion handlers.
Asynchronous channels are
a special type of channel capable of asynchronous I/O operations. Asynchronous
channels are non-blocking and define methods to initiate asynchronous
operations, returning an IoFuture representing
the pending result of each operation. The IoFuture can be used to poll
or wait for the result of the operation. Asynchronous I/O operations can also
specify a CompletionHandler to invoke when
the operation completes. A completion handler is user provided code that is
executed to consume the result of I/O operation.
This package defines asynchronous-channel classes that are connected to
a stream-oriented connecting or listening socket, or a datagram-oriented
socket. [[NOT IMPLEMENTED: It also defines the
AsynchronousFileChannel class
for asynchronous reading, writing, and manipulating a file. As with the
FileChannel it supports operations to truncate the file
to a specific size, force updates to the file to be written to the storage
device, or acquire locks on the whole file or on a specific region of the
file. Unlike the FileChannel it does not define methods for mapping a
region of the file directly into memory. Where memory mapped I/O is required,
then a FileChannel can be used.]]
Asynchronous channels are bound to an asynchronous channel group for the
purpose of resource sharing. A group has an associated
ExecutorService to which tasks
are submitted to handle I/O events and dispatch to completion handlers that
consume the result of asynchronous operations performed on channels in the
group. The group can optionally be specified when creating the channel or the
channel can be bound to a default group. Sophisticated users may
wish to create their own asynchronous channel groups or configure the
ExecutorService that will be used for the default group.
As with selectors, the implementation of asynchronous channels can be
replaced by "plugging in" an alternative definition or instance of the
AsynchronousChannelProvider
class defined in the java.nio.channels.spi package.
It is not expected that many developers will actually make use of this
facility; it is provided primarily so that sophisticated users can take
advantage of operating-system-specific asynchronous I/O mechanisms when very
high performance is required.
Unless otherwise noted, passing a null argument to a constructor
or method in any class or interface in this package will cause a
NullPointerException to be thrown.
|
RedDwarf, Version 0.10.1 2010-03-14 10:56:12 |
|||||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | |||||||||