MCPcopy Create free account
hub / github.com/bitcoin/bitcoin / ParseParam

Function ParseParam

src/rpc/client.cpp:432–436  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

430} // namespace rpc_convert
431
432static UniValue ParseParam(const CRPCConvertParam* param, std::string_view raw)
433{
434 // Only parse parameters which have the JSON or JSON_OR_STRING format; otherwise, treat them as strings.
435 return (param && (param->format == ParamFormat::JSON || param->format == ParamFormat::JSON_OR_STRING)) ? Parse(raw, param->format) : UniValue(std::string(raw));
436}
437
438/**
439 * Convert command lines arguments to params object when -named is disabled.

Callers 2

RPCConvertValuesFunction · 0.85
RPCConvertNamedValuesFunction · 0.85

Calls 2

ParseFunction · 0.70
UniValueClass · 0.70

Tested by

no test coverage detected