Top Description Fields Constructors Methods
org.apache.hc.core5.http2.hpack

pack-priv final Class HuffmanNode

extends Object
Class Inheritance
Imports
java.util.Arrays, org.apache.hc.core5.util.Asserts

This Huffman codec implementation has been derived from Twitter HPack project (https://github.com/twitter/hpack)

Field Summary

Modifier and TypeField and Description
private final int
private final HuffmanNode[]
private final int

Constructor Summary

AccessConstructor and Description
pack-priv
pack-priv
HuffmanNode(final int symbol, final int bits)

Method Summary

Modifier and TypeMethod and Description
public int
public HuffmanNode
getChild(final int index)

public int
public boolean
hasChild(final int index)

public boolean
pack-priv void
setChild(final int index, final HuffmanNode child)

public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

bitsback to summary
private final int bits
childrenback to summary
private final HuffmanNode[] children
symbolback to summary
private final int symbol

Constructor Detail

HuffmanNodeback to summary
pack-priv HuffmanNode()
HuffmanNodeback to summary
pack-priv HuffmanNode(final int symbol, final int bits)

Method Detail

getBitsback to summary
public int getBits()
getChildback to summary
public HuffmanNode getChild(final int index)
getSymbolback to summary
public int getSymbol()
hasChildback to summary
public boolean hasChild(final int index)
isTerminalback to summary
public boolean isTerminal()
setChildback to summary
pack-priv void setChild(final int index, final HuffmanNode child)
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object.

Returns:String

a string representation of the object.

Annotations
@Override