Class HpackContext

java.lang.Object
org.eclipse.jetty.http2.hpack.HpackContext

public class HpackContext extends Object
HPACK - Header Compression for HTTP/2

This class maintains the compression context for a single HTTP/2 connection. Specifically it holds the static and dynamic Header Field Tables and the associated sizes and limits.

It is compliant with draft 11 of the specification

  • Field Details

  • Constructor Details

    • HpackContext

      HpackContext(int maxTableSize)
  • Method Details

    • resize

      public void resize(int newMaxDynamicTableSize)
    • get

      public HpackContext.Entry get(org.eclipse.jetty.http.HttpField field)
    • get

      public HpackContext.Entry get(String name)
    • get

      public HpackContext.Entry get(int index)
    • get

      public HpackContext.Entry get(org.eclipse.jetty.http.HttpHeader header)
    • getStatic

      public static HpackContext.Entry getStatic(org.eclipse.jetty.http.HttpHeader header)
    • add

      public HpackContext.Entry add(org.eclipse.jetty.http.HttpField field)
    • size

      public int size()
      Returns:
      Current dynamic table size in entries
    • getDynamicTableSize

      public int getDynamicTableSize()
      Returns:
      Current Dynamic table size in Octets
    • getMaxDynamicTableSize

      public int getMaxDynamicTableSize()
      Returns:
      Max Dynamic table size in Octets
    • index

      public int index(HpackContext.Entry entry)
    • staticIndex

      public static int staticIndex(org.eclipse.jetty.http.HttpHeader header)
    • toString

      public String toString()
      Overrides:
      toString in class Object