public class SniffyAsynchronousSocketChannel extends AsynchronousSocketChannel implements SniffyNetworkConnection
DEFAULT_TCP_WINDOW_SIZE| Constructor and Description |
|---|
SniffyAsynchronousSocketChannel(AsynchronousChannelProvider provider,
AsynchronousSocketChannel delegate) |
provider, read, writepublic SniffyAsynchronousSocketChannel(AsynchronousChannelProvider provider, AsynchronousSocketChannel delegate)
public void setConnectionStatus(Integer connectionStatus)
setConnectionStatus in interface SniffyNetworkConnectionpublic InetSocketAddress getInetSocketAddress()
getInetSocketAddress in interface SniffyNetworkConnection@Deprecated public void logSocket(long millis)
logSocket in interface SniffyNetworkConnection@Deprecated public void logSocket(long millis, int bytesDown, int bytesUp)
logSocket in interface SniffyNetworkConnectionpublic void logTraffic(boolean sent,
Protocol protocol,
byte[] traffic,
int off,
int len)
logTraffic in interface TrafficCapturingNetworkConnectionpublic void checkConnectionAllowed()
throws ConnectException
checkConnectionAllowed in interface SniffyNetworkConnectionConnectExceptionpublic void checkConnectionAllowed(int numberOfSleepCycles)
throws ConnectException
checkConnectionAllowed in interface SniffyNetworkConnectionConnectExceptionpublic void checkConnectionAllowed(InetSocketAddress inetSocketAddress) throws ConnectException
checkConnectionAllowed in interface SniffyNetworkConnectionConnectExceptionpublic void checkConnectionAllowed(InetSocketAddress inetSocketAddress, int numberOfSleepCycles) throws ConnectException
checkConnectionAllowed in interface SniffyNetworkConnectionConnectExceptionpublic static AsynchronousSocketChannel open(AsynchronousChannelGroup group) throws IOException
IOExceptionpublic static AsynchronousSocketChannel open() throws IOException
IOExceptionpublic AsynchronousSocketChannel bind(SocketAddress local) throws IOException
bind in interface NetworkChannelbind in class AsynchronousSocketChannelIOExceptionpublic <T> AsynchronousSocketChannel setOption(SocketOption<T> name, T value) throws IOException
setOption in interface NetworkChannelsetOption in class AsynchronousSocketChannelIOExceptionpublic AsynchronousSocketChannel shutdownInput() throws IOException
shutdownInput in class AsynchronousSocketChannelIOExceptionpublic AsynchronousSocketChannel shutdownOutput() throws IOException
shutdownOutput in class AsynchronousSocketChannelIOExceptionpublic SocketAddress getRemoteAddress() throws IOException
getRemoteAddress in class AsynchronousSocketChannelIOExceptionpublic <A> void connect(SocketAddress remote, A attachment, CompletionHandler<Void,? super A> handler)
connect in class AsynchronousSocketChannelpublic Future<Void> connect(SocketAddress remote)
connect in class AsynchronousSocketChannelpublic <A> void read(ByteBuffer dst, long timeout, TimeUnit unit, A attachment, CompletionHandler<Integer,? super A> handler)
read in class AsynchronousSocketChannelpublic Future<Integer> read(ByteBuffer dst)
read in interface AsynchronousByteChannelread in class AsynchronousSocketChannelpublic <A> void read(ByteBuffer[] dsts, int offset, int length, long timeout, TimeUnit unit, A attachment, CompletionHandler<Long,? super A> handler)
read in class AsynchronousSocketChannelpublic <A> void write(ByteBuffer src, long timeout, TimeUnit unit, A attachment, CompletionHandler<Integer,? super A> handler)
write in class AsynchronousSocketChannelpublic Future<Integer> write(ByteBuffer src)
write in interface AsynchronousByteChannelwrite in class AsynchronousSocketChannelpublic <A> void write(ByteBuffer[] srcs, int offset, int length, long timeout, TimeUnit unit, A attachment, CompletionHandler<Long,? super A> handler)
write in class AsynchronousSocketChannelpublic SocketAddress getLocalAddress() throws IOException
getLocalAddress in interface NetworkChannelgetLocalAddress in class AsynchronousSocketChannelIOExceptionpublic void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in interface AsynchronousChannelclose in interface ChannelIOExceptionpublic <T> T getOption(SocketOption<T> name) throws IOException
getOption in interface NetworkChannelIOExceptionpublic Set<SocketOption<?>> supportedOptions()
supportedOptions in interface NetworkChannelpublic int getPotentiallyBufferedInputBytes()
getPotentiallyBufferedInputBytes in interface SniffyNetworkConnectionpublic void setPotentiallyBufferedInputBytes(int potentiallyBufferedInputBytes)
setPotentiallyBufferedInputBytes in interface SniffyNetworkConnectionpublic int getPotentiallyBufferedOutputBytes()
getPotentiallyBufferedOutputBytes in interface SniffyNetworkConnectionpublic void setPotentiallyBufferedOutputBytes(int potentiallyBufferedOutputBytes)
setPotentiallyBufferedOutputBytes in interface SniffyNetworkConnectionpublic long getLastReadThreadId()
getLastReadThreadId in interface SniffyNetworkConnectionpublic void setLastReadThreadId(long lastReadThreadId)
setLastReadThreadId in interface SniffyNetworkConnectionpublic long getLastWriteThreadId()
getLastWriteThreadId in interface SniffyNetworkConnectionpublic void setLastWriteThreadId(long lastWriteThreadId)
setLastWriteThreadId in interface SniffyNetworkConnectionCopyright © 2021. All rights reserved.