YODA::AOReaderBase Class Referenceabstract
Inheritance diagram for YODA::AOReaderBase:
Detailed DescriptionDefinition at line 40 of file ReaderUtils.h. Constructor & Destructor Documentation◆ AOReaderBase()
◆ ~AOReaderBase()
Member Function Documentation◆ assemble()
◆ extractVector()
template<typename T >
Definition at line 134 of file ReaderUtils.h. 134 {
135 if constexpr (std::is_same<T, std::string>::value) {
136 string::const_iterator initpos( line.cbegin() );
137 const string::const_iterator finpos( line.cend() );
138 std::smatch m;
139 while ( std::regex_search(initpos, finpos, m, regex_string_pat) ) {
140 string label;
141 std::stringstream ss(m[0].str());
142 ss >> std::quoted(label); // removes outer quotes and de-escapes inner quotes
143 vec.push_back(label);
144 initpos = m.suffix().first;
145 }
146 }
147 else {
148 std::string content = line.substr(line.find(": [")+3);
149 content.pop_back(); // remove the "]" at the end
150 for (const std::string& item : Utils::split(content, ",")) {
151 aiss.reset(item);
152 T tmp;
153 aiss >> tmp;
154 vec.push_back(std::move(tmp));
155 }
156 }
157 }
References aiss. ◆ parse()
Member Data Documentation◆ aiss
Definition at line 161 of file ReaderUtils.h. Referenced by extractVector(). The documentation for this class was generated from the following file:
Generated on Mon Oct 28 2024 13:47:24 for YODA - Yet more Objects for Data Analysis by 1.9.8 |