|
|
|
| DynamicWaveletTree () |
| | Default constructor with |T| = 0 and |U| = 0.
|
| |
|
| DynamicWaveletTree (const std::vector< uint8_t > &_alphabet) |
| | Default constructor with |T| = 0 and U = _alphabet.
|
| |
|
| ~DynamicWaveletTree () |
| | Destroy the Dynamic Wavelet Tree object.
|
| |
|
| DynamicWaveletTree (DynamicWaveletTree &&) noexcept=default |
| | Default move constructor.
|
| |
|
|
DynamicWaveletTree & | operator= (const DynamicWaveletTree &)=delete |
| | Deleted copy assignment operator.
|
| |
|
DynamicWaveletTree & | operator= (DynamicWaveletTree &&) noexcept=default |
| | Default move assignment operator.
|
| |
|
uint8_t | operator[] (uint64_t i) const |
| | The alias for at query.
|
| |
|
|
uint64_t | size () const |
| | Return |T|.
|
| |
|
uint64_t | get_alphabet_size () const |
| | Return alphabet size |U|.
|
| |
|
bool | has_empty_alphabet () const |
| | Check if the alphabet U is empty.
|
| |
|
uint64_t | get_smallest_character_in_alphabet () const |
| | Return the smallest character in the alphabet U.
|
| |
|
int64_t | get_lexicographic_order (uint8_t c) const |
| | Return the lexicographic order of a given character c in the alphabet U if it exists, otherwise returns -1.
|
| |
|
uint64_t | height () const |
| | Return the height of the wavelet tree.
|
| |
| uint64_t | size_in_bytes (bool only_dynamic_memory=false) const |
| | Returns the total memory usage in bytes.
|
| |
|
| uint64_t | at (uint64_t i) const |
| | Return T[i].
|
| |
| int64_t | one_based_rank (uint64_t i, uint64_t c) const |
| | Counts the number of occurrences of a character c in T[0..i-1].
|
| |
| int64_t | select (uint64_t i, uint64_t c) const |
| | Returns the position p of the (i+1)-th 1 in B if such a position exists, otherwise returns -1.
|
| |
| uint64_t | get_lexicographic_order_by_position (uint64_t i) const |
| | Return the lexicographic order of T[i] in the alphabet U.
|
| |
| uint64_t | count_c (uint8_t c) const |
| | Return the number of occurrences of the character c in T.
|
| |
|
|
std::string | to_string () const |
| | Return T as a string.
|
| |
|
std::vector< uint8_t > | to_u8_vector () const |
| | Return T as a vector of uint8_t.
|
| |
|
std::vector< uint8_t > | to_alphabet_vector () const |
| | Return the alphabet U.
|
| |
|
|
void | swap (DynamicWaveletTree &item) |
| | Swap operation.
|
| |
|
void | set_alphabet (const std::vector< uint8_t > &_alphabet) |
| | Initialize this instance with |T| = 0 and U = _alphabet.
|
| |
|
void | clear () |
| | Clear the elements in T.
|
| |
| void | push_back (uint8_t c) |
| | Adds a character c to the end of T.
|
| |
| void | push_many (const std::vector< uint8_t > &str) |
| | Add a given sequence Q[0..k-1] to the end of T[0..n-1] (i.e., T = T[0..n-1]Q[0..k-1])
|
| |
| void | insert (uint64_t i, uint8_t c) |
| | Insert a character c into T as T[i].
|
| |
| void | remove (uint64_t i) |
| | Remove the character at the position i from T.
|
| |
|
| std::vector< std::string > | get_memory_usage_info (int message_paragraph=stool::Message::SHOW_MESSAGE) const |
| | Return the memory usage information of this data structure as a vector of strings.
|
| |
| void | print_statistics (int message_paragraph=stool::Message::SHOW_MESSAGE) const |
| | Print the statistics of this data structure.
|
| |
| void | print_memory_usage (int message_paragraph=stool::Message::SHOW_MESSAGE) const |
| | Print the memory usage information of this data structure.
|
| |
| void | print_content (int message_paragraph=stool::Message::SHOW_MESSAGE) const |
| | Print the string T.
|
| |
|
void | print_info () const |
| | Print the statistics of this data structure.
|
| |
A dynamic data structure supporting rank and select queries on a string T[0..n-1] over alphabet U[0..σ-1].