Decentralised Art Server
High-performance C++ backend that exposes HTML interface and a secure REST API for managing Performative Transactions entities
 
Loading...
Searching...
No Matches
parser.hpp
Go to the documentation of this file.
1#pragma once
2
3#include <nlohmann/json.hpp>
4using json = nlohmann::json;
5
6#include <google/protobuf/util/json_util.h>
7
8namespace dcn::parse
9{
11
12 struct use_json_t{};
13
19 static constexpr use_protobuf_t use_protobuf{};
20
26 static constexpr use_json_t use_json{};
27
28
29 template<class T>
30 std::optional<T> parseFromJson(json json, use_json_t);
31
32 template<class T>
33 std::optional<T> parseFromJson(std::string json_str, use_protobuf_t);
34}
Definition auth.hpp:34
std::optional< T > parseFromJson(json json, use_json_t)
Parses a JSON object to a Transformation object.
nlohmann::json json
Definition parser.hpp:4
Definition parser.hpp:12
Definition parser.hpp:10