MCPcopy Create free account
hub / github.com/WolfireGames/overgrowth / ASAddJSON

Method ASAddJSON

Source/Scripting/scriptparams.cpp:282–289  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

280}
281
282void ScriptParams::ASAddJSON(const std::string &key, SimpleJSONWrapper &details) {
283 if (parameter_map_.find(key) != parameter_map_.end()) {
284 return;
285 }
286 ScriptParam sp;
287 sp.SetJSON(details);
288 parameter_map_.insert(std::pair<std::string, ScriptParam>(key, sp));
289}
290
291SimpleJSONWrapper ScriptParams::ASGetJSON(const std::string &key) {
292 ScriptParamMap::iterator iter = parameter_map_.find(key);

Callers

nothing calls this directly

Calls 4

SetJSONMethod · 0.80
findMethod · 0.45
endMethod · 0.45
insertMethod · 0.45

Tested by

no test coverage detected