Package org.eclipse.jetty.http3
Class InstructionStreamConnection
java.lang.Object
org.eclipse.jetty.io.AbstractConnection
org.eclipse.jetty.http3.InstructionStreamConnection
- All Implemented Interfaces:
Closeable
,AutoCloseable
,Connection
,Connection.UpgradeTo
,Invocable
- Direct Known Subclasses:
DecoderStreamConnection
,EncoderStreamConnection
public abstract class InstructionStreamConnection
extends AbstractConnection
implements Connection.UpgradeTo
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.eclipse.jetty.io.Connection
Connection.Listener, Connection.UpgradeFrom, Connection.UpgradeTo
Nested classes/interfaces inherited from interface org.eclipse.jetty.util.thread.Invocable
Invocable.Callable, Invocable.InvocationType, Invocable.ReadyTask, Invocable.Task
-
Field Summary
Fields inherited from interface org.eclipse.jetty.util.thread.Invocable
__nonBlocking, NOOP
-
Constructor Summary
ConstructorDescriptionInstructionStreamConnection
(EndPoint endPoint, Executor executor, ByteBufferPool bufferPool, ParserListener listener) -
Method Summary
Modifier and TypeMethodDescriptionboolean
protected void
notifySessionFailure
(long error, String reason, Throwable failure) void
Callback method invoked when the endpoint is ready to be read.void
onOpen()
Callback method invoked when this connection is opened.void
onUpgradeTo
(ByteBuffer upgrade) Invoked during anupgrade
to receive a buffer containing bytes that have not been consumed by the upgrade-from connection, and that must be consumed by this connection.protected abstract void
parseInstruction
(ByteBuffer buffer) void
setUseInputDirectByteBuffers
(boolean useInputDirectByteBuffers) Methods inherited from class org.eclipse.jetty.io.AbstractConnection
addEventListener, close, failedCallback, fillInterested, getBytesIn, getBytesOut, getCreatedTimeStamp, getEndPoint, getExecutor, getInputBufferSize, getInvocationType, getMessagesIn, getMessagesOut, isFillInterested, onClose, onFillInterestedFailed, onIdleExpired, onReadTimeout, removeEventListener, setInputBufferSize, toConnectionString, toString, tryFillInterested
-
Constructor Details
-
InstructionStreamConnection
public InstructionStreamConnection(EndPoint endPoint, Executor executor, ByteBufferPool bufferPool, ParserListener listener)
-
-
Method Details
-
isUseInputDirectByteBuffers
public boolean isUseInputDirectByteBuffers() -
setUseInputDirectByteBuffers
public void setUseInputDirectByteBuffers(boolean useInputDirectByteBuffers) -
onUpgradeTo
Description copied from interface:Connection.UpgradeTo
Invoked during an
upgrade
to receive a buffer containing bytes that have not been consumed by the upgrade-from connection, and that must be consumed by this connection.- Specified by:
onUpgradeTo
in interfaceConnection.UpgradeTo
- Parameters:
upgrade
- a non-null buffer of unconsumed bytes received from the upgrade-from connection. The buffer does not belong to any pool and should be discarded after having consumed its bytes.
-
onOpen
public void onOpen()Description copied from interface:Connection
Callback method invoked when this connection is opened.
Creators of the connection implementation are responsible for calling this method.
- Specified by:
onOpen
in interfaceConnection
- Overrides:
onOpen
in classAbstractConnection
-
onFillable
public void onFillable()Description copied from class:AbstractConnection
Callback method invoked when the endpoint is ready to be read.
- Specified by:
onFillable
in classAbstractConnection
- See Also:
-
notifySessionFailure
-
parseInstruction
- Throws:
QpackException
-