public abstract class ProxyConnection extends AbstractConnection
Modifier and Type | Class and Description |
---|---|
private class |
ProxyConnection.ProxyIteratingCallback |
Connection.Listener, Connection.UpgradeFrom, Connection.UpgradeTo
Modifier and Type | Field and Description |
---|---|
private ByteBufferPool |
bufferPool |
private Connection |
connection |
private java.util.concurrent.ConcurrentMap<java.lang.String,java.lang.Object> |
context |
protected static Logger |
LOG |
private IteratingCallback |
pipe |
Modifier | Constructor and Description |
---|---|
protected |
ProxyConnection(EndPoint endp,
java.util.concurrent.Executor executor,
ByteBufferPool bufferPool,
java.util.concurrent.ConcurrentMap<java.lang.String,java.lang.Object> context) |
Modifier and Type | Method and Description |
---|---|
ByteBufferPool |
getByteBufferPool() |
Connection |
getConnection() |
java.util.concurrent.ConcurrentMap<java.lang.String,java.lang.Object> |
getContext() |
void |
onFillable()
Callback method invoked when the endpoint is ready to be read.
|
protected abstract int |
read(EndPoint endPoint,
java.nio.ByteBuffer buffer) |
void |
setConnection(Connection connection) |
java.lang.String |
toConnectionString() |
protected abstract void |
write(EndPoint endPoint,
java.nio.ByteBuffer buffer,
Callback callback) |
addListener, close, failedCallback, fillInterested, getBytesIn, getBytesOut, getCreatedTimeStamp, getEndPoint, getExecutor, getInputBufferSize, getMessagesIn, getMessagesOut, isFillInterested, onClose, onFillInterestedFailed, onIdleExpired, onOpen, onReadTimeout, removeListener, setInputBufferSize, toString, tryFillInterested, tryFillInterested
protected static final Logger LOG
private final IteratingCallback pipe
private final ByteBufferPool bufferPool
private final java.util.concurrent.ConcurrentMap<java.lang.String,java.lang.Object> context
private Connection connection
protected ProxyConnection(EndPoint endp, java.util.concurrent.Executor executor, ByteBufferPool bufferPool, java.util.concurrent.ConcurrentMap<java.lang.String,java.lang.Object> context)
public ByteBufferPool getByteBufferPool()
public java.util.concurrent.ConcurrentMap<java.lang.String,java.lang.Object> getContext()
public Connection getConnection()
public void setConnection(Connection connection)
public void onFillable()
AbstractConnection
Callback method invoked when the endpoint is ready to be read.
onFillable
in class AbstractConnection
AbstractConnection.fillInterested()
protected abstract int read(EndPoint endPoint, java.nio.ByteBuffer buffer) throws java.io.IOException
java.io.IOException
protected abstract void write(EndPoint endPoint, java.nio.ByteBuffer buffer, Callback callback)
public java.lang.String toConnectionString()
toConnectionString
in class AbstractConnection