public static class Nio2Channel.ClosedNio2Channel extends Nio2Channel
Nio2Channel.ClosedNio2ChannelbufHandler, emptyBuf, sc, socket| 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.
|
java.util.concurrent.Future<java.lang.Integer> |
read(java.nio.ByteBuffer dst) |
<A> void |
read(java.nio.ByteBuffer[] dsts,
int offset,
int length,
long timeout,
java.util.concurrent.TimeUnit unit,
A attachment,
java.nio.channels.CompletionHandler<java.lang.Long,? super A> handler) |
<A> void |
read(java.nio.ByteBuffer dst,
long timeout,
java.util.concurrent.TimeUnit unit,
A attachment,
java.nio.channels.CompletionHandler<java.lang.Integer,? super A> handler) |
void |
reset(java.nio.channels.AsynchronousSocketChannel channel,
SocketWrapperBase<Nio2Channel> socket)
Reset the channel.
|
void |
setAppReadBufHandler(ApplicationBufferHandler handler) |
java.lang.String |
toString() |
java.util.concurrent.Future<java.lang.Integer> |
write(java.nio.ByteBuffer src) |
<A> void |
write(java.nio.ByteBuffer[] srcs,
int offset,
int length,
long timeout,
java.util.concurrent.TimeUnit unit,
A attachment,
java.nio.channels.CompletionHandler<java.lang.Long,? super A> handler) |
<A> void |
write(java.nio.ByteBuffer src,
long timeout,
java.util.concurrent.TimeUnit unit,
A attachment,
java.nio.channels.CompletionHandler<java.lang.Integer,? super A> handler) |
close, flush, getAppReadBufHandler, getBufHandler, getIOChannel, getSocket, handshake, isClosing, isHandshakeComplete, read, writepublic void close()
throws java.io.IOException
Nio2Channelclose in interface java.io.Closeableclose in interface java.lang.AutoCloseableclose in interface java.nio.channels.AsynchronousChannelclose in interface java.nio.channels.Channelclose in class Nio2Channeljava.io.IOException - If an I/O error occurspublic boolean isOpen()
Nio2ChannelisOpen in interface java.nio.channels.ChannelisOpen in class Nio2Channelpublic void reset(java.nio.channels.AsynchronousSocketChannel channel,
SocketWrapperBase<Nio2Channel> socket)
throws java.io.IOException
Nio2Channelreset in class Nio2Channelchannel - The new async channel to associate with this NIO2 channelsocket - The new socket to associate with this NIO2 channeljava.io.IOException - If a problem was encountered resetting the channelpublic void free()
Nio2Channelfree in class Nio2Channelpublic void setAppReadBufHandler(ApplicationBufferHandler handler)
setAppReadBufHandler in class Nio2Channelpublic java.util.concurrent.Future<java.lang.Integer> read(java.nio.ByteBuffer dst)
read in interface java.nio.channels.AsynchronousByteChannelread in class Nio2Channelpublic <A> void read(java.nio.ByteBuffer dst,
long timeout,
java.util.concurrent.TimeUnit unit,
A attachment,
java.nio.channels.CompletionHandler<java.lang.Integer,? super A> handler)
read in class Nio2Channelpublic <A> void read(java.nio.ByteBuffer[] dsts,
int offset,
int length,
long timeout,
java.util.concurrent.TimeUnit unit,
A attachment,
java.nio.channels.CompletionHandler<java.lang.Long,? super A> handler)
read in class Nio2Channelpublic java.util.concurrent.Future<java.lang.Integer> write(java.nio.ByteBuffer src)
write in interface java.nio.channels.AsynchronousByteChannelwrite in class Nio2Channelpublic <A> void write(java.nio.ByteBuffer src,
long timeout,
java.util.concurrent.TimeUnit unit,
A attachment,
java.nio.channels.CompletionHandler<java.lang.Integer,? super A> handler)
write in class Nio2Channelpublic <A> void write(java.nio.ByteBuffer[] srcs,
int offset,
int length,
long timeout,
java.util.concurrent.TimeUnit unit,
A attachment,
java.nio.channels.CompletionHandler<java.lang.Long,? super A> handler)
write in class Nio2Channelpublic java.lang.String toString()
toString in class Nio2ChannelCopyright © 2000-2019 Apache Software Foundation. All Rights Reserved.