Doxygen
|
Object representing the match results of a capture range. More...
#include <src/regex.h>
Public Member Functions | |
SubMatch (std::string_view str) | |
Creates a match for a single capture range given a non-owning pointer to the string. | |
size_t | position () const |
Returns the position in the string at which the match starts. | |
size_t | length () const |
Returns the length of the matching part. | |
std::string | str () const |
Returns the matching part as a string. | |
Private Member Functions | |
void | setStart (size_t pos) |
void | setEnd (size_t pos) |
void | setMatch (size_t pos, size_t len) |
Private Attributes | |
size_t | m_pos = std::string::npos |
size_t | m_len = std::string::npos |
std::string_view | m_str |
Friends | |
class | Match |
|
inline |
Creates a match for a single capture range given a non-owning pointer to the string.
Definition at line 122 of file regex.h.
|
inline |
|
inline |
|
inlineprivate |
|
inlineprivate |
Definition at line 137 of file regex.h.
Referenced by reg::Match::prefix(), and reg::Match::suffix().
|
inlineprivate |
|
inline |
|
friend |
|
private |
|
private |
Definition at line 138 of file regex.h.
Referenced by position(), setEnd(), setMatch(), setStart(), and str().
|
private |
Definition at line 140 of file regex.h.
Referenced by str(), and SubMatch().