Handling key exceptions on the variable itself

This is the first step towords to solve #1697
This commit is contained in:
Felipe Zimmerle
2018-09-20 09:08:08 -03:00
parent 0d53111cb0
commit ee50fea266
54 changed files with 2337 additions and 2080 deletions

View File

@@ -32,7 +32,8 @@ Variable::Variable(std::string name)
: m_name(name),
m_collectionName(""),
m_isExclusion(false),
m_isCount(false) {
m_isCount(false),
m_regex("") {
size_t a = m_name.find(":");
if (a == std::string::npos) {
a = m_name.find(".");
@@ -40,7 +41,8 @@ Variable::Variable(std::string name)
if (a != std::string::npos) {
m_collectionName = utils::string::toupper(std::string(m_name, 0, a));
m_name = std::string(m_name, a + 1, m_name.size());
m_fullName = std::make_shared<std::string>(m_collectionName + ":" + m_name);
m_fullName = std::make_shared<std::string>(m_collectionName
+ ":" + m_name);
} else {
m_fullName = std::make_shared<std::string>(m_name);
m_collectionName = m_name;
@@ -49,6 +51,9 @@ Variable::Variable(std::string name)
}
std::string Variable::to_s(
std::vector<Variable *> *variables) {
std::string ret;