24#ifndef JSON_SERIALIZERS_H_
25#define JSON_SERIALIZERS_H_
27#include <nlohmann/json.hpp>
31NLOHMANN_JSON_NAMESPACE_BEGIN
37struct char_traits<wxUniChar> : std::char_traits<char>
50NLOHMANN_JSON_NAMESPACE_END
55struct adl_serializer<wxString>
59 s = wxString::FromUTF8( j.get<std::string>().c_str() );
62 static void to_json(
json& j,
const wxString& s ) { j = s.ToUTF8(); }
66struct adl_serializer<
std::optional<T>>
76 opt = j.template get<T>();
static char_type to_char_type(int_type i) noexcept
static int_type to_int_type(char_type c) noexcept
static constexpr int_type eof() noexcept
static void to_json(json &j, const std::optional< T > &opt)
static void from_json(const json &j, std::optional< T > &opt)
static void from_json(const json &j, wxString &s)
static void to_json(json &j, const wxString &s)