FOSSology
4.4.0
Open Source License Compliance by Open Source Software
|
Handles RegexMap related requests. More...
#include "regexConfParser.hpp"
#include <string>
#include <iostream>
Go to the source code of this file.
Macros | |
#define | RGX_SEPARATOR_LEFT "__" |
#define | RGX_SEPARATOR_RIGHT RGX_SEPARATOR_LEFT |
#define | RGX_SEPARATOR_LEN 2 |
Functions | |
RegexMap | readConfStreamToMap (std::istringstream &stream, const bool isVerbosityDebug) |
Read a string stream and crate a RegexMap. More... | |
RegexMap | readConfStreamToMap (std::ifstream &stream, const bool isVerbosityDebug) |
void | addRegexToMap (RegexMap ®exMap, const std::string ®exDesc, const bool isVerbosityDebug) |
Given a single line as 'key=value' pair, create a RegexMap. More... | |
string | replaceTokens (RegexMap ®exMap, const string &constInput) |
Removes tokens separated by RGX_SEPARATOR_LEFT in constInput using regexMap. More... | |
Handles RegexMap related requests.
Definition in file regexConfParser.cc.
void addRegexToMap | ( | RegexMap & | regexMap, |
const std::string & | regexDesc, | ||
const bool | isVerbosityDebug | ||
) |
Given a single line as 'key=value' pair, create a RegexMap.
[out] | regexMap | Map to add pairs |
[in] | regexDesc | String containing the pair to be added |
[in] | isVerbosityDebug | Print debug messages if true |
Definition at line 53 of file regexConfParser.cc.
RegexMap readConfStreamToMap | ( | std::ifstream & | stream, |
const bool | isVerbosityDebug | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 36 of file regexConfParser.cc.
RegexMap readConfStreamToMap | ( | std::istringstream & | stream, |
const bool | isVerbosityDebug | ||
) |
Read a string stream and crate a RegexMap.
stream | String stream to read from |
isVerbosityDebug | Print debug messages if true |
Definition at line 23 of file regexConfParser.cc.
string replaceTokens | ( | RegexMap & | regexMap, |
const string & | constInput | ||
) |
Removes tokens separated by RGX_SEPARATOR_LEFT in constInput using regexMap.
[in] | regexMap | Map to be used for removal |
[in] | constInput | Input which has to be removed |
Definition at line 89 of file regexConfParser.cc.