0.2.0
Loading...
Searching...
No Matches
Json.hpp File Reference

Defines how to save certain datatypes to json. More...

Go to the source code of this file.

Classes

struct  nlohmann::adl_serializer< std::variant< Args... > >
 ADL serializer for JSON. More...
 
struct  detail::variant_switch< N >
 Variant serialize implementation. More...
 
struct  detail::variant_switch< 0 >
 Variant serialize implementation specialization for a single variant. More...
 

Typedefs

using json
 json namespace
 

Functions

void from_json (const json &j, ImColor &color)
 Converts the provided json object into a color.
 
void from_json (const json &j, ImPlotStyle &style)
 Converts the provided json object into a vector.
 
void from_json (const json &j, ImVec2 &vec2)
 Converts the provided json object into a vector.
 
void from_json (const json &j, ImVec4 &vec4)
 Converts the provided json object into a vector.
 
void to_json (json &j, const ImColor &color)
 Converts the provided color into a json object.
 
void to_json (json &j, const ImPlotStyle &style)
 Converts the provided vector into a json object.
 
void to_json (json &j, const ImVec2 &vec2)
 Converts the provided vector into a json object.
 
void to_json (json &j, const ImVec4 &vec4)
 Converts the provided vector into a json object.
 

Detailed Description

Defines how to save certain datatypes to json.

Author
T. Topp (topp@.nosp@m.ins..nosp@m.uni-s.nosp@m.tutt.nosp@m.gart..nosp@m.de)
Date
2021-08-10

Function Documentation

◆ from_json() [1/4]

void from_json ( const json & j,
ImColor & color )

Converts the provided json object into a color.

Parameters
[in]jJson object with the color values
[out]colorColor to return

◆ from_json() [2/4]

void from_json ( const json & j,
ImPlotStyle & style )

Converts the provided json object into a vector.

Parameters
[in]jJson object with the vector values
[out]styleStyle to return

◆ from_json() [3/4]

void from_json ( const json & j,
ImVec2 & vec2 )

Converts the provided json object into a vector.

Parameters
[in]jJson object with the vector values
[out]vec2Vector to return

◆ from_json() [4/4]

void from_json ( const json & j,
ImVec4 & vec4 )

Converts the provided json object into a vector.

Parameters
[in]jJson object with the vector values
[out]vec4Vector to return

◆ to_json() [1/4]

void to_json ( json & j,
const ImColor & color )

Converts the provided color into a json object.

Parameters
[out]jReturn Json object
[in]colorColor to convert

◆ to_json() [2/4]

void to_json ( json & j,
const ImPlotStyle & style )

Converts the provided vector into a json object.

Parameters
[out]jReturn Json object
[in]styleStyle to convert

◆ to_json() [3/4]

void to_json ( json & j,
const ImVec2 & vec2 )

Converts the provided vector into a json object.

Parameters
[out]jReturn Json object
[in]vec2Vector to convert

◆ to_json() [4/4]

void to_json ( json & j,
const ImVec4 & vec4 )

Converts the provided vector into a json object.

Parameters
[out]jReturn Json object
[in]vec4Vector to convert