![]() |
Roc Toolkit internal modules
Roc Toolkit: real-time audio streaming
|
Dynamic list of strings. More...
#include <roc_core/string_list.h>

Public Member Functions | |
| StringList (IArena &arena) | |
| Initialize empty string list. | |
| size_t | size () const |
| Get number of elements. | |
| bool | is_empty () const |
| Check if list is empty. | |
| const char * | front () const |
| Get first string. | |
| const char * | back () const |
| Get last string. | |
| const char * | nextof (const char *str) const |
| Get next string. | |
| const char * | prevof (const char *str) const |
| Get previous string. | |
| void | clear () |
| Clear the list. | |
| bool | push_back (const char *str) |
| Append string to the list. | |
| bool | push_back (const char *str_begin, const char *str_end) |
| Append string from a range to the list. | |
| const char * | find (const char *str) |
| Find string in the list. | |
| const char * | find (const char *str_begin, const char *str_end) |
| Find string in the list. | |
Dynamic list of strings.
Strings are stored in a countinous dynamically-growing array. Each string is stored in a block with a header and footer, which both store block length. This allow fast iteration in both directions.
Definition at line 36 of file string_list.h.
|
explicit |
Initialize empty string list.
| const char * roc::core::StringList::back | ( | ) | const |
Get last string.
| void roc::core::StringList::clear | ( | ) |
Clear the list.
Find string in the list.
Find string in the list.
| const char * roc::core::StringList::front | ( | ) | const |
Get first string.
| bool roc::core::StringList::is_empty | ( | ) | const |
Check if list is empty.
| bool roc::core::StringList::push_back | ( | const char * | str | ) |
Append string to the list.
Append string from a range to the list.
| size_t roc::core::StringList::size | ( | ) | const |
Get number of elements.