Home / Function/ decodeIndexed() — netty Function Reference

decodeIndexed() — netty Function Reference

Architecture documentation for the decodeIndexed() function in QpackDecoder.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  e4c523f1_b420_82d8_ae49_39b9bbc2cdce["decodeIndexed()"]
  90fa2d3f_8d04_4c74_e2ce_52229be77194["QpackDecoder"]
  e4c523f1_b420_82d8_ae49_39b9bbc2cdce -->|defined in| 90fa2d3f_8d04_4c74_e2ce_52229be77194
  678f973e_104e_7340_6c3b_b4ef23003fe0["decode()"]
  678f973e_104e_7340_6c3b_b4ef23003fe0 -->|calls| e4c523f1_b420_82d8_ae49_39b9bbc2cdce
  style e4c523f1_b420_82d8_ae49_39b9bbc2cdce fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

codec-http3/src/main/java/io/netty/handler/codec/http3/QpackDecoder.java lines 291–314

    private void decodeIndexed(ByteBuf in, BiConsumer<CharSequence, CharSequence> sink, int base)
            throws QpackException {
        // https://www.rfc-editor.org/rfc/rfc9204.html#name-indexed-field-line
        //   0   1   2   3   4   5   6   7
        // +---+---+---+---+---+---+---+---+
        // | 1 | T |      Index (6+)       |
        // +---+---+-----------------------+
        //
        // T == 1 implies static table
        final QpackHeaderField field;
        if (firstByteEquals(in, (byte) 0b1100_0000)) {
            final int idx = decodePrefixedIntegerAsInt(in, 6);
            assert idx >= 0;
            if (idx >= QpackStaticTable.length) {
                throw HEADER_ILLEGAL_INDEX_VALUE;
            }
            field = QpackStaticTable.getField(idx);
        } else {
            final int idx = decodePrefixedIntegerAsInt(in, 6);
            assert idx >= 0;
            field = dynamicTable.getEntryRelativeEncodedField(base - idx - 1);
        }
        sink.accept(field.name, field.value);
    }

Domain

Subdomains

Called By

Frequently Asked Questions

What does decodeIndexed() do?
decodeIndexed() is a function in the netty codebase, defined in codec-http3/src/main/java/io/netty/handler/codec/http3/QpackDecoder.java.
Where is decodeIndexed() defined?
decodeIndexed() is defined in codec-http3/src/main/java/io/netty/handler/codec/http3/QpackDecoder.java at line 291.
What calls decodeIndexed()?
decodeIndexed() is called by 1 function(s): decode.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free