![]() |
KASKADE 7 development version
|
#include <prefixcoder.hh>
Public Types | |
| using | State = State_ |
Public Member Functions | |
| PrefixCode (CodeBook< State, Symbol > &&codebook_) | |
| int | maxLen () const |
| Returns the maximum length of any codeword (in bits). | |
| std::pair< State, int > | code (Symbol s) const |
| For a symbol \( s \), return the pair \( (c,n) \) of code word \( c \) (in the least significant bits) and code length \( n\). | |
| bool | hasSymbol (Symbol s) const |
| Checks whether the given symbol exists in the codebook. | |
| std::pair< Symbol, int > | symbol (State code) const |
| For an encoded message fraction of \( m \) bits ( \( m \) being the maximum code length), return the pair \( (s,n) \) of symbol \( s \) and code length \( n \). | |
| void | printCodebook () const |
Definition at line 52 of file prefixcoder.hh.
| using PrefixCode< Symbol, State_ >::State = State_ |
Definition at line 94 of file prefixcoder.hh.
|
inline |
Definition at line 96 of file prefixcoder.hh.
|
inline |
For a symbol \( s \), return the pair \( (c,n) \) of code word \( c \) (in the least significant bits) and code length \( n\).
Definition at line 130 of file prefixcoder.hh.
Referenced by PrefixEncoder< Symbol, OIter, Output, State >::push_back(), and symbol().
|
inline |
Checks whether the given symbol exists in the codebook.
Definition at line 141 of file prefixcoder.hh.
|
inline |
Returns the maximum length of any codeword (in bits).
Definition at line 121 of file prefixcoder.hh.
|
inline |
Definition at line 156 of file prefixcoder.hh.
|
inline |
For an encoded message fraction of \( m \) bits ( \( m \) being the maximum code length), return the pair \( (s,n) \) of symbol \( s \) and code length \( n \).
Definition at line 151 of file prefixcoder.hh.
Referenced by PrefixDecoder< Symbol, IIter, Input, State >::pop_front(), PrefixCode(), and printCodebook().