setOption() — netty Function Reference
Architecture documentation for the setOption() function in AbstractHttp2StreamChannel.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 858ecbbc_23c8_402a_e077_28f8ef14ee8b["setOption()"] ec726ae3_04b2_4a4d_cded_16e4166256ed["Http2StreamChannelConfig"] 858ecbbc_23c8_402a_e077_28f8ef14ee8b -->|defined in| ec726ae3_04b2_4a4d_cded_16e4166256ed 4388645f_109b_b524_2309_8f2334e3229f["isRegistered()"] 858ecbbc_23c8_402a_e077_28f8ef14ee8b -->|calls| 4388645f_109b_b524_2309_8f2334e3229f 4719f032_82eb_05bb_5db2_1ba1daf73d78["updateLocalWindowIfNeededAndFlush()"] 858ecbbc_23c8_402a_e077_28f8ef14ee8b -->|calls| 4719f032_82eb_05bb_5db2_1ba1daf73d78 style 858ecbbc_23c8_402a_e077_28f8ef14ee8b fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
codec-http2/src/main/java/io/netty/handler/codec/http2/AbstractHttp2StreamChannel.java lines 1241–1266
@Override
public <T> boolean setOption(ChannelOption<T> option, T value) {
validate(option, value);
if (option == Http2StreamChannelOption.AUTO_STREAM_FLOW_CONTROL) {
boolean newValue = (Boolean) value;
boolean changed = newValue && !autoStreamFlowControl;
autoStreamFlowControl = (Boolean) value;
if (changed) {
if (channel.isRegistered()) {
final Http2ChannelUnsafe unsafe = (Http2ChannelUnsafe) channel.unsafe();
if (channel.eventLoop().inEventLoop()) {
unsafe.updateLocalWindowIfNeededAndFlush();
} else {
channel.eventLoop().execute(new Runnable() {
@Override
public void run() {
unsafe.updateLocalWindowIfNeededAndFlush();
}
});
}
}
}
return true;
}
return super.setOption(option, value);
}
Domain
Subdomains
Source
Frequently Asked Questions
What does setOption() do?
setOption() is a function in the netty codebase, defined in codec-http2/src/main/java/io/netty/handler/codec/http2/AbstractHttp2StreamChannel.java.
Where is setOption() defined?
setOption() is defined in codec-http2/src/main/java/io/netty/handler/codec/http2/AbstractHttp2StreamChannel.java at line 1241.
What does setOption() call?
setOption() calls 2 function(s): isRegistered, updateLocalWindowIfNeededAndFlush.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free