ezconfig
Create C++ Objects from Yaml and Json
|
Json factory forward declarations. More...
Go to the source code of this file.
Classes | |
struct | nlohmann::adl_serializer< std::shared_ptr< Base > > |
Converter json -> std::shared_ptr<Base> using json::Create(). More... | |
struct | nlohmann::adl_serializer< std::unique_ptr< Base > > |
Converter json -> std::unique_ptr<Base> using json::Create(). More... | |
Concepts | |
concept | ezconfig::json::Constructible |
Macros | |
#define | EZ_JSON_DECLARE(Base) |
Declare a json factory for a base class. | |
Functions | |
template<typename Base > | |
std::unique_ptr< Base > | ezconfig::json::Create (const nlohmann::json &j) |
Create an object using the factory. | |
Json factory forward declarations.
Include this file in the header for the base class.
Definition in file json_fwd.hpp.
#define EZ_JSON_DECLARE | ( | Base | ) |
Declare a json factory for a base class.
Base | factory base class. |
The factory creates pointers to Base.
Example: Declare a MyBase json factory.
Definition at line 50 of file json_fwd.hpp.
std::unique_ptr< Base > ezconfig::json::Create | ( | const nlohmann::json & | j | ) |