Class HpackEncoder

java.lang.Object
dev.relism.flash.http2.hpack.HpackEncoder

public final class HpackEncoder extends Object
Stateless HPACK encoder for response header blocks. It uses the RFC 7541 static table and literal fields without indexing; consequently, concurrent streams never share mutable encoder state.
  • Method Details

    • writeDynamicTableSizeUpdateZero

      public static void writeDynamicTableSizeUpdateZero(ByteWriter out)
      Declares that this endpoint will not use an encoder-side dynamic table.
    • writeIndexed

      public static void writeIndexed(ByteWriter out, int staticIndex)
    • writeLiteral

      public static void writeLiteral(ByteWriter out, byte[] name, byte[] value)
    • writeLiteral

      public static void writeLiteral(ByteWriter out, dev.relism.fpr.core.ByteView name, dev.relism.fpr.core.ByteView value)
      Writes a non-indexed literal directly from protocol-neutral byte views.
    • writeLiteral

      public static void writeLiteral(ByteWriter out, byte[] name, int nameOff, int nameLen, byte[] value, int valueOff, int valueLen, boolean huffmanValue)
    • writeLiteralWithNameIndex

      public static void writeLiteralWithNameIndex(ByteWriter out, int nameIndex, byte[] value, boolean huffmanValue)
    • writeLiteralWithNameIndex

      public static void writeLiteralWithNameIndex(ByteWriter out, int nameIndex, byte[] value, int valueOff, int valueLen, boolean huffmanValue)
    • writeLiteralNeverIndexed

      public static void writeLiteralNeverIndexed(ByteWriter out, byte[] name, byte[] value, boolean huffmanValue)
    • writeLiteralNeverIndexedWithNameIndex

      public static void writeLiteralNeverIndexedWithNameIndex(ByteWriter out, int nameIndex, byte[] value, boolean huffmanValue)