MCPcopy Create free account
hub / github.com/apache/arrow / GetBool

Method GetBool

cpp/src/arrow/json/object_parser.cc:73–81  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

71 }
72
73 Result<bool> GetBool(const char* key) const {
74 if (!document_.HasMember(key)) {
75 return Status::KeyError("Key '", key, "' does not exist");
76 }
77 if (!document_[key].IsBool()) {
78 return Status::TypeError("Key '", key, "' is not a boolean");
79 }
80 return document_[key].GetBool();
81 }
82
83 private:
84 rj::Document document_;

Callers

nothing calls this directly

Calls 3

KeyErrorFunction · 0.85
TypeErrorFunction · 0.50
GetBoolMethod · 0.45

Tested by

no test coverage detected