42 unsigned int consumed;
50 throw std::runtime_error{
"The string '" + str +
"' is not a valid JSON number"};
60 std::ostringstream oss;
69 std::ostringstream oss;
78 std::ostringstream oss;
80 oss << std::setprecision(16) << val_;
122 keys.push_back(std::move(key));
142 for (
size_t i = 0; i < obj.
keys.size(); i++)
152 for (
size_t i = 0; i <
keys.size(); i++)
158 for (
size_t i = 0; i <
keys.size(); i++) {
159 if (
keys[i] == key) {
174 for (
const auto&
object:
t) {
176 if (!
findKey(
object.first, idx)) {
180 if (
values.at(idx).getType() !=
object.second) {
204 if (index >=
values.size())
212 if (
typ != expected) {
235 for (
unsigned int i = 0; i <
keys.size(); ++i) {
236 if (
keys[i] == key) {
void push_back(UniValue val)
bool checkObject(const std::map< std::string, UniValue::VType > &memberTypes) const
const UniValue & find_value(std::string_view key) const
void pushKVs(UniValue obj)
void setInt(uint64_t val)
void pushKVEnd(std::string key, UniValue val)
std::vector< UniValue > values
std::vector< std::string > keys
void checkType(const VType &expected) const
bool findKey(const std::string &key, size_t &retIdx) const
const UniValue & operator[](const std::string &key) const
void setFloat(double val)
void setStr(std::string str)
void pushKV(std::string key, UniValue val)
void setNumStr(std::string str)
void getObjMap(std::map< std::string, UniValue > &kv) const
void push_backV(const std::vector< UniValue > &vec)
static bool validNumStr(const std::string &s)
const UniValue NullUniValue
const char * uvTypeName(UniValue::VType t)
enum jtokentype getJsonToken(std::string &tokenVal, unsigned int &consumed, const char *raw, const char *end)