19 #include "regscan.hpp" 26 const string& identity,
35 rx::regex_constants::icase);
45 std::istringstream& stream,
54 rx::regex_constants::icase);
65 string::const_iterator end = s.end();
66 string::const_iterator pos = s.begin();
67 unsigned int intPos = 0;
73 if (rx::regex_search(pos, end, res,
_reg))
76 results.push_back(
match(intPos + res.position(
_index),
80 intPos += res.position() + res.length();
Provide regex using conf file.
Store the results of a regex match.
int s
The socket that the CLI will use to communicate.
const char * getRegexValue(const std::string &name, const std::string &key)
Get the regex as string from the RegexMap.
void ScanString(const string &str, list< match > &results) const
Scan a string using regex defined during initialization.
regexScanner(const string &type, const string &identity, int index=0)
Initialize RegexConfProvider and regex based on type and identity.
list_t type structure used to keep various lists. (e.g. there are multiple lists).
void maybeLoad(const std::string &identity)
Check if identity already loaded in RegexMap, if not load them.