aboutsummaryrefslogtreecommitdiff
path: root/src/rpcblockchain.cpp
diff options
context:
space:
mode:
authorJonas Schnelli <jonas.schnelli@include7.ch>2015-05-13 21:29:19 +0200
committerJonas Schnelli <jonas.schnelli@include7.ch>2015-06-04 09:16:06 +0200
commit3df0411ad9fd75fb27af53e44835d41f5480fe3f (patch)
tree99e1a50e6b36e69c4429129d87567890b5878b3c /src/rpcblockchain.cpp
parent1f263c899ee0756ed9ed133f35bec18bdef20cdc (diff)
remove JSON Spirit UniValue wrapper
Diffstat (limited to 'src/rpcblockchain.cpp')
-rw-r--r--src/rpcblockchain.cpp30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/rpcblockchain.cpp b/src/rpcblockchain.cpp
index facc112cb4..f20f9f994d 100644
--- a/src/rpcblockchain.cpp
+++ b/src/rpcblockchain.cpp
@@ -53,7 +53,7 @@ double GetDifficulty(const CBlockIndex* blockindex)
}
-Object blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool txDetails = false)
+UniValue blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool txDetails = false)
{
UniValue result(UniValue::VOBJ);
result.push_back(Pair("hash", block.GetHash().GetHex()));
@@ -94,7 +94,7 @@ Object blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool txDe
}
-Value getblockcount(const Array& params, bool fHelp)
+UniValue getblockcount(const Array& params, bool fHelp)
{
if (fHelp || params.size() != 0)
throw runtime_error(
@@ -111,7 +111,7 @@ Value getblockcount(const Array& params, bool fHelp)
return chainActive.Height();
}
-Value getbestblockhash(const Array& params, bool fHelp)
+UniValue getbestblockhash(const Array& params, bool fHelp)
{
if (fHelp || params.size() != 0)
throw runtime_error(
@@ -128,7 +128,7 @@ Value getbestblockhash(const Array& params, bool fHelp)
return chainActive.Tip()->GetBlockHash().GetHex();
}
-Value getdifficulty(const Array& params, bool fHelp)
+UniValue getdifficulty(const Array& params, bool fHelp)
{
if (fHelp || params.size() != 0)
throw runtime_error(
@@ -146,7 +146,7 @@ Value getdifficulty(const Array& params, bool fHelp)
}
-Value getrawmempool(const Array& params, bool fHelp)
+UniValue getrawmempool(const Array& params, bool fHelp)
{
if (fHelp || params.size() > 1)
throw runtime_error(
@@ -231,7 +231,7 @@ Value getrawmempool(const Array& params, bool fHelp)
}
}
-Value getblockhash(const Array& params, bool fHelp)
+UniValue getblockhash(const Array& params, bool fHelp)
{
if (fHelp || params.size() != 1)
throw runtime_error(
@@ -256,7 +256,7 @@ Value getblockhash(const Array& params, bool fHelp)
return pblockindex->GetBlockHash().GetHex();
}
-Value getblock(const Array& params, bool fHelp)
+UniValue getblock(const Array& params, bool fHelp)
{
if (fHelp || params.size() < 1 || params.size() > 2)
throw runtime_error(
@@ -324,7 +324,7 @@ Value getblock(const Array& params, bool fHelp)
return blockToJSON(block, pblockindex);
}
-Value gettxoutsetinfo(const Array& params, bool fHelp)
+UniValue gettxoutsetinfo(const Array& params, bool fHelp)
{
if (fHelp || params.size() != 0)
throw runtime_error(
@@ -364,7 +364,7 @@ Value gettxoutsetinfo(const Array& params, bool fHelp)
return ret;
}
-Value gettxout(const Array& params, bool fHelp)
+UniValue gettxout(const Array& params, bool fHelp)
{
if (fHelp || params.size() < 2 || params.size() > 3)
throw runtime_error(
@@ -444,7 +444,7 @@ Value gettxout(const Array& params, bool fHelp)
return ret;
}
-Value verifychain(const Array& params, bool fHelp)
+UniValue verifychain(const Array& params, bool fHelp)
{
if (fHelp || params.size() > 2)
throw runtime_error(
@@ -472,7 +472,7 @@ Value verifychain(const Array& params, bool fHelp)
return CVerifyDB().VerifyDB(pcoinsTip, nCheckLevel, nCheckDepth);
}
-Value getblockchaininfo(const Array& params, bool fHelp)
+UniValue getblockchaininfo(const Array& params, bool fHelp)
{
if (fHelp || params.size() != 0)
throw runtime_error(
@@ -530,7 +530,7 @@ struct CompareBlocksByHeight
}
};
-Value getchaintips(const Array& params, bool fHelp)
+UniValue getchaintips(const Array& params, bool fHelp)
{
if (fHelp || params.size() != 0)
throw runtime_error(
@@ -620,7 +620,7 @@ Value getchaintips(const Array& params, bool fHelp)
return res;
}
-Value getmempoolinfo(const Array& params, bool fHelp)
+UniValue getmempoolinfo(const Array& params, bool fHelp)
{
if (fHelp || params.size() != 0)
throw runtime_error(
@@ -643,7 +643,7 @@ Value getmempoolinfo(const Array& params, bool fHelp)
return ret;
}
-Value invalidateblock(const Array& params, bool fHelp)
+UniValue invalidateblock(const Array& params, bool fHelp)
{
if (fHelp || params.size() != 1)
throw runtime_error(
@@ -681,7 +681,7 @@ Value invalidateblock(const Array& params, bool fHelp)
return NullUniValue;
}
-Value reconsiderblock(const Array& params, bool fHelp)
+UniValue reconsiderblock(const Array& params, bool fHelp)
{
if (fHelp || params.size() != 1)
throw runtime_error(