MCPcopy Create free account
hub / github.com/MhmRdd/NoHello / parse

Method parse

module/src/main/cpp/mountsinfo.cpp:103–117  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

101 std::unordered_map<std::string, std::string> flagmap;
102
103 void parse(const std::string& str) {
104 std::istringstream s(str);
105 std::string opt;
106 while (std::getline(s, opt, ',')) {
107 auto it = mountFlags.find(opt);
108 if (it != mountFlags.end()) {
109 flags |= it->second;
110 } else {
111 size_t eq = opt.find('=');
112 if (eq != std::string::npos) {
113 flagmap[opt.substr(0, eq)] = opt.substr(eq + 1);
114 }
115 }
116 }
117 }
118};
119
120class MountInfo {

Callers 1

parseOptionsMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected