A class for iterating over each character in a string. More...
#include <stringIterator.hpp>
Public Member Functions | |
stringIterator (uint8_t *ptr, size_t offset) noexcept | |
Constructor. | |
stringIterator | operator++ () noexcept |
Increment the current character we're pointing to. | |
bool | operator!= (const stringIterator &other) const noexcept |
Equality operator. | |
const uint32_t & | operator* () const noexcept |
Dereference operator. | |
A class for iterating over each character in a string.
Since some string encoding schemes (i.e. UTF-8) have multi-character sequences That represent a single "character", this iterator allows for looping over each character in strings of different encoding identically.
|
noexcept |
Constructor.
ptr | Pointer to the string data. |
offset | The current index in the string data. |
|
inlinenoexcept |
Equality operator.
other | The object to compare to. |
|
inlinenoexcept |
Dereference operator.
|
noexcept |
Increment the current character we're pointing to.