Remove JSON Spirit wrapper, remove JSON Spirit leftovers

- implement find_value() function for UniValue
- replace all Array/Value/Object types with UniValues, remove JSON Spirit to UniValue wrapper
- remove JSON Spirit sources
This commit is contained in:
Jonas Schnelli
2015-05-18 14:02:18 +02:00
committed by Jack Grigg
parent 851f58f94e
commit d014114d67
37 changed files with 212 additions and 2209 deletions

View File

@@ -19,9 +19,8 @@
#include <boost/algorithm/string.hpp>
#include <boost/date_time/posix_time/posix_time.hpp>
#include "json_spirit_wrapper.h"
#include "univalue/univalue.h"
using namespace json_spirit;
using namespace std;
void EnsureWalletIsUnlocked();
@@ -74,7 +73,7 @@ std::string DecodeDumpString(const std::string &str) {
return ret.str();
}
UniValue importprivkey(const Array& params, bool fHelp)
UniValue importprivkey(const UniValue& params, bool fHelp)
{
if (!EnsureWalletIsAvailable(fHelp))
return NullUniValue;
@@ -148,7 +147,7 @@ UniValue importprivkey(const Array& params, bool fHelp)
return NullUniValue;
}
UniValue importaddress(const Array& params, bool fHelp)
UniValue importaddress(const UniValue& params, bool fHelp)
{
if (!EnsureWalletIsAvailable(fHelp))
return NullUniValue;
@@ -244,7 +243,7 @@ Value z_importwallet(const Array& params, bool fHelp)
return importwallet_impl(params, fHelp, true);
}
UniValue importwallet(const Array& params, bool fHelp)
UniValue importwallet(const UniValue& params, bool fHelp)
{
if (!EnsureWalletIsAvailable(fHelp))
return NullUniValue;
@@ -381,7 +380,7 @@ Value importwallet_impl(const Array& params, bool fHelp, bool fImportZKeys)
return NullUniValue;
}
UniValue dumpprivkey(const Array& params, bool fHelp)
UniValue dumpprivkey(const UniValue& params, bool fHelp)
{
if (!EnsureWalletIsAvailable(fHelp))
return NullUniValue;
@@ -441,7 +440,7 @@ Value z_exportwallet(const Array& params, bool fHelp)
return dumpwallet_impl(params, fHelp, true);
}
UniValue dumpwallet(const Array& params, bool fHelp)
UniValue dumpwallet(const UniValue& params, bool fHelp)
{
if (!EnsureWalletIsAvailable(fHelp))
return NullUniValue;