MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / SnakeToCamelCase

Function SnakeToCamelCase

tensorflow/java/src/gen/cc/op_specs.cc:171–186  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

169}
170
171string SnakeToCamelCase(const string& str, bool upper = false) {
172 string result;
173 bool cap = upper;
174 for (string::const_iterator it = str.begin(); it != str.end(); ++it) {
175 const char c = *it;
176 if (c == '_') {
177 cap = true;
178 } else if (cap) {
179 result += toupper(c);
180 cap = false;
181 } else {
182 result += c;
183 }
184 }
185 return result;
186}
187
188bool FindAndCut(string* input, const RE2& expr, string* before_match,
189 string* ret_match = nullptr) {

Callers 3

CreateInputFunction · 0.85
CreateAttributeFunction · 0.85
CreateOutputFunction · 0.85

Calls 2

beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected