29#ifndef NOMLIB_SERIALIZERS_JSONCPP_SERIALIZER_HPP
30#define NOMLIB_SERIALIZERS_JSONCPP_SERIALIZER_HPP
35#include "nomlib/config.hpp"
36#include "nomlib/serializers/serializers_config.hpp"
37#include "nomlib/serializers/IValueSerializer.hpp"
38#include "nomlib/ptree.hpp"
58const std::string JSONCPP_INDENTION_LEVEL =
" ";
99 bool save(
const Value& source,
const std::string& filename );
102 enum SerializerOptions options_;
104 bool write(
const Value& source, Json::Value& dest )
const;
123std::unique_ptr<IValueSerializer> make_unique_json_serializer();
bool write_object(const Value &object, Json::Value &dest) const
Internal helper method for serialization of object nodes.
bool save(const Value &source, const std::string &filename)
Convenience method provided to output JSON-formatted data to a file.
std::string serialize(const Value &source)
Output a nom::Value object to a string.
bool write_value(const Value &object, Json::Value &dest) const
JsonCppSerializer(enum SerializerOptions options)
Construct a parser with a feature set enumeration.
bool write_array_value(const Value &object, Json::Value &dest) const
JsonCppSerializer(void)
Default constructor; initialize the writer with human friendly output.
bool write_array(const Value &object, Json::Value &dest) const
Internal helper method for serialization of array nodes.
~JsonCppSerializer(void)
Destructor.
Generic interface for opaque data containers.