Huffman decoder.
More...
#include <Huffman.H>
Huffman decoder.
- See also
- Huffman_Encoder_Engine
Definition at line 747 of file Huffman.H.
◆ Huffman_Decoder_Engine()
| Aleph::Huffman_Decoder_Engine::Huffman_Decoder_Engine |
( |
BinNode< std::string > * |
p, |
|
|
const std::string & |
end |
|
) |
| |
|
inline |
Decoder constructor.
Builds a decoder given a previously constructed Huffman tree.
- Parameters
-
| [in] | p | Root of the Huffman decoding tree. |
| [in] | end | End-of-stream symbol. |
Definition at line 760 of file Huffman.H.
◆ decode()
| void Aleph::Huffman_Decoder_Engine::decode |
( |
const BitArray & |
bit_stream, |
|
|
std::ostream & |
output |
|
) |
| const |
|
inline |
Decode a bit stream.
decode(bit_stream, output) decodes bit_stream using the Huffman prefix tree and writes the decoded output into output.
- Parameters
-
| [in] | bit_stream | Encoded bit stream. |
| [out] | output | Output stream where the decoded text is written. |
Definition at line 781 of file Huffman.H.
References ah_domain_error_if, end_symbol, Aleph::BinNode< Key >::get_key(), Aleph::is_leaf(), LLINK, output, Aleph::BitArray::read_bit(), RLINK, root, and Aleph::BitArray::size().
Referenced by main(), and main().
◆ get_root()
| BinNode< std::string > *& Aleph::Huffman_Decoder_Engine::get_root |
( |
| ) |
|
|
inline |
◆ end_symbol
| std::string Aleph::Huffman_Decoder_Engine::end_symbol |
|
private |
◆ root
| BinNode<std::string>* Aleph::Huffman_Decoder_Engine::root |
|
private |
The documentation for this class was generated from the following file: