3#include "mc/_HeaderOutputPredefine.h"
7namespace Json {
class Value; }
10namespace JsonHelpers {
13MCNAPI_C
void addIntField(::Json::Value& rootValue, ::std::string
const& fieldName,
int const& value);
15MCNAPI_C
void addStringField(::Json::Value& rootValue, ::std::string
const& fieldName, ::std::string
const& value);
17MCNAPI ::std::string getAsString(::Json::Value
const& value, ::std::string_view defaultString);
19MCNAPI_C ::std::vector<::std::string> getAsStringArray(::Json::Value
const& value);
21MCNAPI_C ::Json::Value
const& getField(::Json::Value
const& rootValue, ::std::string
const& fieldName);
23MCNAPI_C ::Json::Value
const& getFieldAsArray(::Json::Value
const& rootValue, ::std::string
const& fieldName);
25MCNAPI_C
bool getFieldAsBool(::Json::Value
const& rootValue, ::std::string
const& fieldName,
bool defaultBool);
27MCNAPI_C
float getFieldAsFloat(::Json::Value
const& rootValue, ::std::string
const& fieldName,
float defaultFloat);
29MCNAPI_C
int getFieldAsInt(::Json::Value
const& rootValue, ::std::string
const& fieldName,
int defaultInt);
31MCNAPI_C int64 getFieldAsInt64(::Json::Value
const& rootValue, ::std::string
const& fieldName, int64 defaultInt64);
33MCNAPI_C ::std::unordered_map<::std::string, ::std::string>
34getFieldAsLocDictionary(::Json::Value
const& rootValue, ::std::string
const& fieldName);
36MCNAPI_C ::std::unordered_map<::std::string, ::std::string>
37getFieldAsMapOfKeyValuePairs(::Json::Value
const& rootValue, ::std::string
const& fieldName);
39MCNAPI_C ::Json::Value
const& getFieldAsObject(::Json::Value
const& rootValue, ::std::string
const& fieldName);
41MCNAPI_C ::std::vector<::std::reference_wrapper<::Json::Value const>>
42getFieldAsObjectArray(::Json::Value
const& rootValue, ::std::string
const& fieldName);
45getFieldAsString(::Json::Value
const& rootValue, ::std::string
const& fieldName, ::std::string
const& defaultString);
47MCNAPI_C ::std::vector<::std::string>
48getFieldAsStringArray(::Json::Value
const& rootValue, ::std::string
const& fieldName);
50MCNAPI_C uint64 getFieldAsUint64(::Json::Value
const& rootValue, ::std::string
const& fieldName, uint64 defaultUint64);
52MCNAPI_C
bool hasField(::Json::Value
const& rootValue, ::std::string
const& fieldName);
54MCNAPI_C
bool parseJson(::std::string
const& str, ::Json::Value& root);
56MCNAPI_C ::std::string serialize(::Json::Value
const& root);