use const references where appropriate

This commit is contained in:
Philip Kaufmann
2015-05-31 15:36:44 +02:00
committed by Jack Grigg
parent 5e478618e6
commit db954a65ac
20 changed files with 60 additions and 61 deletions

View File

@@ -61,7 +61,7 @@ bool IsRPCRunning();
std::shared_ptr<AsyncRPCQueue> getAsyncRPCQueue();
/**
/**
* Set the RPC warmup status. When this is done, all RPC calls will error out
* immediately with RPC_IN_WARMUP.
*/
@@ -116,8 +116,8 @@ private:
std::map<std::string, const CRPCCommand*> mapCommands;
public:
CRPCTable();
const CRPCCommand* operator[](std::string name) const;
std::string help(std::string name) const;
const CRPCCommand* operator[](const std::string& name) const;
std::string help(const std::string& name) const;
/**
* Execute a method.
@@ -149,8 +149,8 @@ extern UniValue ValueFromAmount(const CAmount& amount);
extern double GetDifficulty(const CBlockIndex* blockindex = NULL);
extern double GetNetworkDifficulty(const CBlockIndex* blockindex = NULL);
extern std::string HelpRequiringPassphrase();
extern std::string HelpExampleCli(std::string methodname, std::string args);
extern std::string HelpExampleRpc(std::string methodname, std::string args);
extern std::string HelpExampleCli(const std::string& methodname, const std::string& args);
extern std::string HelpExampleRpc(const std::string& methodname, const std::string& args);
extern void EnsureWalletIsUnlocked();