The Iterator
Class Reference
Class to iterate through matches. More...
Declaration
class reg::Iterator { ... }
Public Member Typedefs Index
Public Constructors Index
| Iterator () |
|
Creates an end-of-sequence iterator. More...
|
|
| Iterator (std::string_view str, const Ex &re, size_t pos=0) |
|
Creates an iterator for input string str, using regular expression re to search. More...
|
|
| Iterator (std::string &&str, const Ex &re)=delete |
|
|
|
| Iterator (const std::string &str, Ex &&re)=delete |
|
|
|
| Iterator (std::string &&str, Ex &&re)=delete |
|
|
|
Public Operators Index
Private Member Functions Index
Private Member Attributes Index
Description
Class to iterate through matches.
Definition at line 231 of file regex.h.
Public Member Typedefs
difference_type
using reg::Iterator::difference_type = std::ptrdiff_t |
|
Definition at line 235 of file regex.h.
iterator_category
using reg::Iterator::iterator_category = std::forward_iterator_tag |
|
Definition at line 238 of file regex.h.
pointer
using reg::Iterator::pointer = value_type* |
|
Definition at line 236 of file regex.h.
reference
using reg::Iterator::reference = value_type& |
|
Definition at line 237 of file regex.h.
value_type
using reg::Iterator::value_type = Match |
|
Definition at line 234 of file regex.h.
Public Constructors
Iterator()
reg::Iterator::Iterator () |
|
inline
|
Iterator()
reg::Iterator::Iterator (std::string_view str, const Ex & re, size_t pos=0) |
|
inline
|
Creates an iterator for input string str, using regular expression re to search.
the string and regular expression objects should remain valid while iterating.
Definition at line 246 of file regex.h.
References findNext, m_pos, m_re and m_str.
Iterator()
reg::Iterator::Iterator (std::string && str, const Ex & re) |
|
delete
|
Definition at line 251 of file regex.h.
Iterator()
reg::Iterator::Iterator (const std::string & str, Ex && re) |
|
delete
|
Definition at line 252 of file regex.h.
Iterator()
reg::Iterator::Iterator (std::string && str, Ex && re) |
|
delete
|
Definition at line 253 of file regex.h.
Public Operators
operator->()
const value_type * reg::Iterator::operator-> () |
|
inline
|
Returns a pointer to the current match.
Definition at line 265 of file regex.h.
Reference m_match.
operator!=()
bool reg::Iterator::operator!= (const Iterator & rhs) |
|
inline
|
Returns true if the iterators are not pointing to the same match.
Definition at line 259 of file regex.h.
References Iterator and m_pos.
operator*()
const value_type & reg::Iterator::operator* () |
|
inline
|
Returns a reference to the current match.
Definition at line 262 of file regex.h.
Reference m_match.
operator++()
Iterator & reg::Iterator::operator++ () |
|
inline
|
operator==()
bool reg::Iterator::operator== (const Iterator & rhs) |
|
inline
|
Returns true if the iterators point to the same match (or both are end-of-sequence iterators)
Definition at line 256 of file regex.h.
References Iterator and m_pos.
Private Member Functions
findNext()
void reg::Iterator::findNext () |
|
inline
|
Private Member Attributes
m_match
Match reg::Iterator::m_match |
|
m_pos
size_t reg::Iterator::m_pos = std::string::npos |
|
m_re
const Ex* reg::Iterator::m_re = nullptr |
|
m_str
std::string_view reg::Iterator::m_str |
|
The documentation for this class was generated from the following file:
Generated via doxygen2docusaurus by Doxygen 1.14.0.