public static class Nio2Channel.ClosedNio2Channel extends Nio2Channel
Nio2Channel.ClosedNio2ChannelbufHandler, emptyBuf, sc, socketWrapper| Constructor and Description |
|---|
ClosedNio2Channel() |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes this channel.
|
void |
free()
Free the channel memory
|
boolean |
isOpen()
Tells whether or not this channel is open.
|
Future<Integer> |
read(ByteBuffer dst) |
<A> void |
read(ByteBuffer[] dsts,
int offset,
int length,
long timeout,
TimeUnit unit,
A attachment,
CompletionHandler<Long,? super A> handler) |
<A> void |
read(ByteBuffer dst,
long timeout,
TimeUnit unit,
A attachment,
CompletionHandler<Integer,? super A> handler) |
void |
reset(AsynchronousSocketChannel channel,
SocketWrapperBase<Nio2Channel> socket)
Reset the channel.
|
void |
setAppReadBufHandler(ApplicationBufferHandler handler) |
String |
toString() |
Future<Integer> |
write(ByteBuffer src) |
<A> void |
write(ByteBuffer[] srcs,
int offset,
int length,
long timeout,
TimeUnit unit,
A attachment,
CompletionHandler<Long,? super A> handler) |
<A> void |
write(ByteBuffer src,
long timeout,
TimeUnit unit,
A attachment,
CompletionHandler<Integer,? super A> handler) |
close, flush, getAppReadBufHandler, getBufHandler, getIOChannel, handshake, isClosing, isHandshakeComplete, read, writepublic void close()
throws IOException
Nio2Channelclose in interface Closeableclose in interface AutoCloseableclose in interface AsynchronousChannelclose in interface Channelclose in class Nio2ChannelIOException - If an I/O error occurspublic boolean isOpen()
Nio2ChannelisOpen in interface ChannelisOpen in class Nio2Channeltrue if, and only if, this channel is openpublic void reset(AsynchronousSocketChannel channel, SocketWrapperBase<Nio2Channel> socket) throws IOException
Nio2Channelreset in class Nio2Channelchannel - The new async channel to associate with this NIO2 channelsocket - The new socket to associate with this NIO2 channelIOException - If a problem was encountered resetting the channelpublic void free()
Nio2Channelfree in class Nio2Channelpublic void setAppReadBufHandler(ApplicationBufferHandler handler)
setAppReadBufHandler in class Nio2Channelpublic Future<Integer> read(ByteBuffer dst)
read in interface AsynchronousByteChannelread in class Nio2Channelpublic <A> void read(ByteBuffer dst, long timeout, TimeUnit unit, A attachment, CompletionHandler<Integer,? super A> handler)
read in class Nio2Channelpublic <A> void read(ByteBuffer[] dsts, int offset, int length, long timeout, TimeUnit unit, A attachment, CompletionHandler<Long,? super A> handler)
read in class Nio2Channelpublic Future<Integer> write(ByteBuffer src)
write in interface AsynchronousByteChannelwrite in class Nio2Channelpublic <A> void write(ByteBuffer src, long timeout, TimeUnit unit, A attachment, CompletionHandler<Integer,? super A> handler)
write in class Nio2Channelpublic <A> void write(ByteBuffer[] srcs, int offset, int length, long timeout, TimeUnit unit, A attachment, CompletionHandler<Long,? super A> handler)
write in class Nio2Channelpublic String toString()
toString in class Nio2ChannelCopyright © 2000-2020 Apache Software Foundation. All Rights Reserved.