Interface DecodingCallback
-
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface public interface DecodingCallback
Delivers results of thedecoding operation
.Methods of the callback are never called by a decoder with any of the arguments being
null
.- Since:
- 9
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description void
onDecoded(java.lang.CharSequence name, java.lang.CharSequence value)
A method the more specific methods of the callback forward their calls to.default void
onDecoded(java.lang.CharSequence name, java.lang.CharSequence value, boolean sensitive)
A more finer-grained version ofonDecoded(CharSequence, CharSequence)
that also reports on value sensitivity.default void
onIndexed(int index, java.lang.CharSequence name, java.lang.CharSequence value)
An Indexed Header Field decoded.default void
onLiteral(int index, java.lang.CharSequence name, java.lang.CharSequence value, boolean valueHuffman)
default void
onLiteral(java.lang.CharSequence name, boolean nameHuffman, java.lang.CharSequence value, boolean valueHuffman)
default void
onLiteralNeverIndexed(int index, java.lang.CharSequence name, java.lang.CharSequence value, boolean valueHuffman)
default void
onLiteralNeverIndexed(java.lang.CharSequence name, boolean nameHuffman, java.lang.CharSequence value, boolean valueHuffman)
default void
onLiteralWithIndexing(int index, java.lang.CharSequence name, java.lang.CharSequence value, boolean valueHuffman)
default void
onLiteralWithIndexing(java.lang.CharSequence name, boolean nameHuffman, java.lang.CharSequence value, boolean valueHuffman)
A Literal Header Field with Incremental Indexing decoded, where both aname
and avalue
were literal.default void
onSizeUpdate(int capacity)
A Dynamic Table Size Update decoded.
-
-
-
Method Detail
-
onDecoded
void onDecoded(java.lang.CharSequence name, java.lang.CharSequence value)
A method the more specific methods of the callback forward their calls to.- Parameters:
name
- header namevalue
- header value
-
onDecoded
default void onDecoded(java.lang.CharSequence name, java.lang.CharSequence value, boolean sensitive)
A more finer-grained version ofonDecoded(CharSequence, CharSequence)
that also reports on value sensitivity.Value sensitivity must be considered, for example, when implementing an intermediary. A
value
is sensitive if it was represented as Literal Header Field Never Indexed.It is required that intermediaries MUST use the same representation for encoding this header field in order to protect its value which is not to be put at risk by compressing it.
- Parameters:
name
- header namevalue
- header valuesensitive
- whether or not the value is sensitive- See Also:
onLiteralNeverIndexed(int, CharSequence, CharSequence, boolean)
,onLiteralNeverIndexed(CharSequence, boolean, CharSequence, boolean)
-
onIndexed
default void onIndexed(int index, java.lang.CharSequence name, java.lang.CharSequence value)
An Indexed Header Field decoded.- Parameters:
index
- index of an entry in the tablename
- header namevalue
- header value
-
onLiteral
default void onLiteral(int index, java.lang.CharSequence name, java.lang.CharSequence value, boolean valueHuffman)
- Parameters:
index
- index of an entry in the tablename
- header namevalue
- header valuevalueHuffman
- if thevalue
was Huffman encoded
-
onLiteral
default void onLiteral(java.lang.CharSequence name, boolean nameHuffman, java.lang.CharSequence value, boolean valueHuffman)
- Parameters:
name
- header namenameHuffman
- if thename
was Huffman encodedvalue
- header valuevalueHuffman
- if thevalue
was Huffman encoded
-
onLiteralNeverIndexed
default void onLiteralNeverIndexed(int index, java.lang.CharSequence name, java.lang.CharSequence value, boolean valueHuffman)
- Parameters:
index
- index of an entry in the tablename
- header namevalue
- header valuevalueHuffman
- if thevalue
was Huffman encoded
-
onLiteralNeverIndexed
default void onLiteralNeverIndexed(java.lang.CharSequence name, boolean nameHuffman, java.lang.CharSequence value, boolean valueHuffman)
- Parameters:
name
- header namenameHuffman
- if thename
was Huffman encodedvalue
- header valuevalueHuffman
- if thevalue
was Huffman encoded
-
onLiteralWithIndexing
default void onLiteralWithIndexing(int index, java.lang.CharSequence name, java.lang.CharSequence value, boolean valueHuffman)
- Parameters:
index
- index of an entry in the tablename
- header namevalue
- header valuevalueHuffman
- if thevalue
was Huffman encoded
-
onLiteralWithIndexing
default void onLiteralWithIndexing(java.lang.CharSequence name, boolean nameHuffman, java.lang.CharSequence value, boolean valueHuffman)
A Literal Header Field with Incremental Indexing decoded, where both aname
and avalue
were literal.- Parameters:
name
- header namenameHuffman
- if thename
was Huffman encodedvalue
- header valuevalueHuffman
- if thevalue
was Huffman encoded
-
onSizeUpdate
default void onSizeUpdate(int capacity)
A Dynamic Table Size Update decoded.- Parameters:
capacity
- new capacity of the header table
-
-