State() — netty Function Reference
Architecture documentation for the State() function in BrotliDecoder.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD f133d60d_f296_abc5_dc2a_aac22a8d324d["State()"] 1ab91a77_63ab_e5b9_9f8e_8e15c08c74e2["BrotliDecoder"] f133d60d_f296_abc5_dc2a_aac22a8d324d -->|defined in| 1ab91a77_63ab_e5b9_9f8e_8e15c08c74e2 637f4f9e_6d96_c331_2d84_0f4d4d324eab["forwardOutput()"] f133d60d_f296_abc5_dc2a_aac22a8d324d -->|calls| 637f4f9e_6d96_c331_2d84_0f4d4d324eab 04616cfa_11f1_d045_4bb0_45a17268e4e4["readBytes()"] f133d60d_f296_abc5_dc2a_aac22a8d324d -->|calls| 04616cfa_11f1_d045_4bb0_45a17268e4e4 style f133d60d_f296_abc5_dc2a_aac22a8d324d fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
codec-compression/src/main/java/io/netty/handler/codec/compression/BrotliDecoder.java lines 76–109
private State decompress(ChannelHandlerContext ctx, ByteBuf input) {
for (;;) {
switch (decoder.getStatus()) {
case DONE:
return State.DONE;
case OK:
decoder.push(0);
break;
case NEEDS_MORE_INPUT:
if (decoder.hasOutput()) {
forwardOutput(ctx);
}
if (!input.isReadable()) {
return State.NEEDS_MORE_INPUT;
}
ByteBuffer decoderInputBuffer = decoder.getInputBuffer();
decoderInputBuffer.clear();
int readBytes = readBytes(input, decoderInputBuffer);
decoder.push(readBytes);
break;
case NEEDS_MORE_OUTPUT:
forwardOutput(ctx);
break;
default:
return State.ERROR;
}
}
}
Domain
Subdomains
Source
Frequently Asked Questions
What does State() do?
State() is a function in the netty codebase, defined in codec-compression/src/main/java/io/netty/handler/codec/compression/BrotliDecoder.java.
Where is State() defined?
State() is defined in codec-compression/src/main/java/io/netty/handler/codec/compression/BrotliDecoder.java at line 76.
What does State() call?
State() calls 2 function(s): forwardOutput, readBytes.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free