ArcdpsExtension
 
Loading...
Searching...
No Matches
nlohmannJsonExtension.h File Reference
#include <optional>
#include <nlohmann/json.hpp>
Include dependency graph for nlohmannJsonExtension.h:

Go to the source code of this file.

Classes

struct  nlohmann::adl_serializer< std::optional< T > >
 

Macros

#define NLOHMANN_JSON_FROM_NON_THROWING(v1)    if (nlohmann_json_j.contains(#v1)) nlohmann_json_j.at(#v1).get_to(nlohmann_json_t.v1);
 
#define NLOHMANN_DEFINE_TYPE_INTRUSIVE_NON_THROWING(Type, ...)
 
#define NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE_NON_THROWING(Type, ...)
 

Macro Definition Documentation

◆ NLOHMANN_DEFINE_TYPE_INTRUSIVE_NON_THROWING

#define NLOHMANN_DEFINE_TYPE_INTRUSIVE_NON_THROWING (   Type,
  ... 
)
Value:
friend void to_json(nlohmann::json& nlohmann_json_j, const Type& nlohmann_json_t) { NLOHMANN_JSON_EXPAND(NLOHMANN_JSON_PASTE(NLOHMANN_JSON_TO, __VA_ARGS__)) } \
friend void from_json(const nlohmann::json& nlohmann_json_j, Type& nlohmann_json_t) { NLOHMANN_JSON_EXPAND(NLOHMANN_JSON_PASTE(NLOHMANN_JSON_FROM_NON_THROWING, __VA_ARGS__)) }
#define NLOHMANN_JSON_FROM_NON_THROWING(v1)
Definition nlohmannJsonExtension.h:6

◆ NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE_NON_THROWING

#define NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE_NON_THROWING (   Type,
  ... 
)
Value:
inline void to_json(nlohmann::json& nlohmann_json_j, const Type& nlohmann_json_t) { NLOHMANN_JSON_EXPAND(NLOHMANN_JSON_PASTE(NLOHMANN_JSON_TO, __VA_ARGS__)) } \
inline void from_json(const nlohmann::json& nlohmann_json_j, Type& nlohmann_json_t) { NLOHMANN_JSON_EXPAND(NLOHMANN_JSON_PASTE(NLOHMANN_JSON_FROM_NON_THROWING, __VA_ARGS__)) }

◆ NLOHMANN_JSON_FROM_NON_THROWING

#define NLOHMANN_JSON_FROM_NON_THROWING (   v1)     if (nlohmann_json_j.contains(#v1)) nlohmann_json_j.at(#v1).get_to(nlohmann_json_t.v1);