Http2FrameWriter Type — netty Architecture
Architecture documentation for the Http2FrameWriter type/interface in Http2FrameWriter.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD acfc0f61_cd95_9f9b_8516_6eb37d838c4d["Http2FrameWriter"] d3d6b891_721c_1d2b_aad4_2d643a574f8d["Http2FrameWriter.java"] acfc0f61_cd95_9f9b_8516_6eb37d838c4d -->|defined in| d3d6b891_721c_1d2b_aad4_2d643a574f8d style acfc0f61_cd95_9f9b_8516_6eb37d838c4d fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
codec-http2/src/main/java/io/netty/handler/codec/http2/Http2FrameWriter.java lines 30–227
public interface Http2FrameWriter extends Http2DataWriter, Closeable {
/**
* Configuration specific to {@link Http2FrameWriter}
*/
interface Configuration {
/**
* Get the {@link Http2HeadersEncoder.Configuration} for this {@link Http2FrameWriter}
*/
Http2HeadersEncoder.Configuration headersConfiguration();
/**
* Get the {@link Http2FrameSizePolicy} for this {@link Http2FrameWriter}
*/
Http2FrameSizePolicy frameSizePolicy();
}
/**
* Writes a HEADERS frame to the remote endpoint.
*
* @param ctx the context to use for writing.
* @param streamId the stream for which to send the frame.
* @param headers the headers to be sent.
* @param padding additional bytes that should be added to obscure the true content size. Must be between 0 and
* 256 (inclusive).
* @param endStream indicates if this is the last frame to be sent for the stream.
* @param promise the promise for the write.
* @return the future for the write.
* <a href="https://tools.ietf.org/html/rfc7540#section-10.5.1">Section 10.5.1</a> states the following:
* <pre>
* The header block MUST be processed to ensure a consistent connection state, unless the connection is closed.
* </pre>
* If this call has modified the HPACK header state you <strong>MUST</strong> throw a connection error.
* <p>
* If this call has <strong>NOT</strong> modified the HPACK header state you are free to throw a stream error.
*/
ChannelFuture writeHeaders(ChannelHandlerContext ctx, int streamId, Http2Headers headers,
int padding, boolean endStream, ChannelPromise promise);
/**
* Writes a HEADERS frame with priority specified to the remote endpoint.
*
* @param ctx the context to use for writing.
* @param streamId the stream for which to send the frame.
* @param headers the headers to be sent.
* @param streamDependency the stream on which this stream should depend, or 0 if it should
* depend on the connection.
* @param weight the weight for this stream.
* @param exclusive whether this stream should be the exclusive dependant of its parent.
* @param padding additional bytes that should be added to obscure the true content size. Must be between 0 and
* 256 (inclusive).
* @param endStream indicates if this is the last frame to be sent for the stream.
* @param promise the promise for the write.
* @return the future for the write.
* <a href="https://tools.ietf.org/html/rfc7540#section-10.5.1">Section 10.5.1</a> states the following:
* <pre>
* The header block MUST be processed to ensure a consistent connection state, unless the connection is closed.
* </pre>
* If this call has modified the HPACK header state you <strong>MUST</strong> throw a connection error.
* <p>
* If this call has <strong>NOT</strong> modified the HPACK header state you are free to throw a stream error.
*/
ChannelFuture writeHeaders(ChannelHandlerContext ctx, int streamId, Http2Headers headers,
int streamDependency, short weight, boolean exclusive, int padding, boolean endStream,
ChannelPromise promise);
/**
* Writes a PRIORITY frame to the remote endpoint.
*
* @param ctx the context to use for writing.
* @param streamId the stream for which to send the frame.
* @param streamDependency the stream on which this stream should depend, or 0 if it should
* depend on the connection.
* @param weight the weight for this stream.
* @param exclusive whether this stream should be the exclusive dependant of its parent.
* @param promise the promise for the write.
* @return the future for the write.
*/
ChannelFuture writePriority(ChannelHandlerContext ctx, int streamId, int streamDependency,
short weight, boolean exclusive, ChannelPromise promise);
/**
Source
Frequently Asked Questions
What is the Http2FrameWriter type?
Http2FrameWriter is a type/interface in the netty codebase, defined in codec-http2/src/main/java/io/netty/handler/codec/http2/Http2FrameWriter.java.
Where is Http2FrameWriter defined?
Http2FrameWriter is defined in codec-http2/src/main/java/io/netty/handler/codec/http2/Http2FrameWriter.java at line 30.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free