dncurrency/nano/node/daemonconfig.hpp
Wesley Shillingford b78941aec1
--diagnostics CLI option to check & update config.json file (#1733)
* --diagonistics now creates config.json file

Formatting

See if this fixes the nano_wallet failure

Actually add it...

Separate config files

Formatting

Formatting

* Formatting
2019-02-22 09:52:26 +00:00

33 lines
763 B
C++

#pragma once
#include <nano/lib/errors.hpp>
#include <nano/node/node.hpp>
#include <nano/node/rpc.hpp>
namespace nano
{
class daemon_config
{
public:
daemon_config ();
nano::error deserialize_json (bool &, nano::jsonconfig &);
nano::error serialize_json (nano::jsonconfig &);
/**
* Returns true if an upgrade occurred
* @param version The version to upgrade to.
* @param config Configuration to upgrade.
*/
bool upgrade_json (unsigned version, nano::jsonconfig & config);
bool rpc_enable;
nano::rpc_config rpc;
nano::node_config node;
bool opencl_enable;
nano::opencl_config opencl;
int json_version () const
{
return 2;
}
};
nano::error read_and_update_daemon_config (boost::filesystem::path const &, nano::daemon_config & config_a);
}