net.sf.jazzlib
Class InflaterHuffmanTree

java.lang.Object
  extended by net.sf.jazzlib.InflaterHuffmanTree

public class InflaterHuffmanTree
extends java.lang.Object


Field Summary
static InflaterHuffmanTree defDistTree
           
static InflaterHuffmanTree defLitLenTree
           
 
Constructor Summary
InflaterHuffmanTree(byte[] codeLengths)
          Constructs a Huffman tree from the array of code lengths.
 
Method Summary
 int getSymbol(net.sf.jazzlib.StreamManipulator input)
          Reads the next symbol from input.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

defLitLenTree

public static InflaterHuffmanTree defLitLenTree

defDistTree

public static InflaterHuffmanTree defDistTree
Constructor Detail

InflaterHuffmanTree

public InflaterHuffmanTree(byte[] codeLengths)
                    throws DataFormatException
Constructs a Huffman tree from the array of code lengths.

Parameters:
codeLengths - the array of code lengths
Throws:
DataFormatException
Method Detail

getSymbol

public int getSymbol(net.sf.jazzlib.StreamManipulator input)
              throws DataFormatException
Reads the next symbol from input. The symbol is encoded using the huffman tree.

Parameters:
input - the input source.
Returns:
the next symbol, or -1 if not enough input is available.
Throws:
DataFormatException