extern "C" __declspec(dllexport) map<string, int> createMap(string &fileName) { ifstream infile(fileName); vector<string> bitsLine; bool headerEnded = false; string line; int i = 0; int length = 0; while (getline(infile, line)) { if (headerEnded) { bitsLine = split(line, ','); signalsMap.insert({ bitsLine.at(0), length }); } else { if (line.find("HEADER_END") != std::string::npos) { headerEnded = true; } } length = infile.tellg(); i++; } return signalsMap; }
Dictionary<string, int> x = createMap("C:/users/asalah/source/repos/WindowsFormsApp3/WindowsFormsApp3/RR_Test2_3.csv");
C++/CLI
std::map
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)