The reg
Namespace Reference
Namespace for the regular expression functions. More...
Definition
Classes Index
class | Ex |
Class representing a regular expression. More... | |
class | Iterator |
Class to iterate through matches. More... | |
class | Match |
Object representing the matching results. More... | |
class | PToken |
Class representing a token in the compiled regular expression token stream. More... | |
class | SubMatch |
Object representing the match results of a capture range. More... | |
Functions Index
static bool | isspace (char c) |
static bool | isalpha (char c) |
static bool | isdigit (char c) |
static bool | isalnum (char c) |
static std::string | wildcard2regex (std::string_view pattern) |
bool | search (std::string_view str, Match &match, const Ex &re, size_t pos=0) |
Search in a given string str starting at position pos for a match against regular expression re. More... | |
bool | search (std::string_view str, const Ex &re, size_t pos=0) |
Search in a given string str starting at position pos for a match against regular expression re. More... | |
bool | match (std::string_view str, Match &match, const Ex &re) |
Matches a given string str for a match against regular expression re. More... | |
bool | match (std::string_view str, const Ex &re) |
Matches a given string str for a match against regular expression re. More... | |
std::string | replace (std::string_view str, const Ex &re, std::string_view replacement) |
Searching in a given input string for parts that match regular expression re and replaces those parts by string replacement. More... | |
Description
Namespace for the regular expression functions.
Functions
isalnum()
| inline static |
isalpha()
| inline static |
Definition at line 38 of file regex.cpp.
Referenced by isalnum and reg::Ex::Private::matchAt.
isdigit()
| inline static |
Definition at line 43 of file regex.cpp.
Referenced by isalnum and reg::Ex::Private::matchAt.
isspace()
| inline static |
Definition at line 33 of file regex.cpp.
Referenced by reg::Ex::Private::matchAt.
match()
Matches a given string str for a match against regular expression re.
Returns true iff a match was found for the whole string. Any capture groups are returned via the match object.
Definition at line 759 of file regex.cpp.
References reg::Ex::match and match.
Referenced by dateTimeFromString, endBrief, genericPatternMatch, getFilterFromList, DocParser::handleStyleArgument, VhdlDocGen::isNumber, match, match, replace, search, search, setOutput and LayoutParser::startLayout.
match()
|
Matches a given string str for a match against regular expression re.
Returns true iff a match was found for the whole string.
Definition at line 764 of file regex.cpp.
References reg::Ex::match and match.
replace()
|
Searching in a given input string for parts that match regular expression re and replaces those parts by string replacement.
Definition at line 770 of file regex.cpp.
References reg::Ex::match and match.
Referenced by VhdlDocGen::addBaseClass, VHDLOutlineParser::checkInlineCode, FlowChart::printNode and replaceAnonymousScopes.
search()
Search in a given string str starting at position pos for a match against regular expression re.
Returns true iff a match was found. Details of what part of the string has matched is returned via the match object.
An example to show how to match all identifiers in a string.
produces:
Definition at line 748 of file regex.cpp.
References reg::Ex::match and match.
Referenced by HtmlHelpIndex::addItem, addValidAliasToMap, addVariable, addVariableToFile, VHDLOutlineParser::checkInlineCode, containsEnvVar, MemberDefImpl::displayDefinition, expandAliasRec, Markdown::Private::extractTitleId, findFunctionPtr, findIndex, MemberDefImpl::getClassDefOfAnonymousType, FormulaManager::initFromRepository, insertDimension, isVarWithConstructor, loadExtensions, loadStylesheet, matchExcludedSymbols, MarkdownOutlineParser::parseInput, runQHelpGenerator, StyleData::setStyle, simplifyTypeForTable, splitKnRArg, StyleData::StyleData, DotAttributes::updateValue, MemberDefImpl::writeDeclaration and MemberDefImpl::writeDocumentation.
search()
|
Search in a given string str starting at position pos for a match against regular expression re.
Returns true iff a match was found.
Definition at line 753 of file regex.cpp.
References reg::Ex::match and match.
wildcard2regex()
| static |
Definition at line 649 of file regex.cpp.
Referenced by reg::Ex::Ex.
The documentation for this namespace was generated from the following file:
Generated via doxygen2docusaurus by Doxygen 1.14.0.