MCPcopy Create free account
hub / github.com/VROOM-Project/vroom / get_string

Function get_string

src/utils/input_parser.cpp:29–38  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27}
28
29inline std::string get_string(const rapidjson::Value& object, const char* key) {
30 std::string value;
31 if (object.HasMember(key)) {
32 if (!object[key].IsString()) {
33 throw InputException("Invalid " + std::string(key) + " value.");
34 }
35 value = object[key].GetString();
36 }
37 return value;
38}
39
40inline double get_double(const rapidjson::Value& object, const char* key) {
41 double value = 1.;

Callers 5

get_breakFunction · 0.85
get_vehicle_stepsFunction · 0.85
get_vehicleFunction · 0.85
get_jobFunction · 0.85
parseFunction · 0.85

Calls 1

InputExceptionClass · 0.85

Tested by

no test coverage detected