Changeset View
Changeset View
Standalone View
Standalone View
src/chainparamsbase.cpp
// Copyright (c) 2010 Satoshi Nakamoto | // Copyright (c) 2010 Satoshi Nakamoto | ||||
// Copyright (c) 2009-2015 The Bitcoin Core developers | // Copyright (c) 2009-2015 The Bitcoin Core developers | ||||
// Distributed under the MIT software license, see the accompanying | // Distributed under the MIT software license, see the accompanying | ||||
// file COPYING or http://www.opensource.org/licenses/mit-license.php. | // file COPYING or http://www.opensource.org/licenses/mit-license.php. | ||||
#include <chainparamsbase.h> | #include <chainparamsbase.h> | ||||
#include <tinyformat.h> | #include <tinyformat.h> | ||||
#include <util.h> | #include <util.h> | ||||
#include <cassert> | #include <cassert> | ||||
const std::string CBaseChainParams::MAIN = "main"; | const std::string CBaseChainParams::MAIN = "main"; | ||||
const std::string CBaseChainParams::TESTNET = "test"; | const std::string CBaseChainParams::TESTNET = "test"; | ||||
const std::string CBaseChainParams::REGTEST = "regtest"; | const std::string CBaseChainParams::REGTEST = "regtest"; | ||||
void AppendParamsHelpMessages(std::string &strUsage, bool debugHelp) { | void SetupChainParamsBaseOptions() { | ||||
strUsage += HelpMessageGroup(_("Chain selection options:")); | gArgs.AddArg("-regtest", | ||||
strUsage += HelpMessageOpt("-testnet", _("Use the test chain")); | "Enter regression test mode, which uses a special chain in " | ||||
if (debugHelp) { | "which blocks can be solved instantly. This is intended for " | ||||
strUsage += HelpMessageOpt( | "regression testing tools and app development.", | ||||
"-regtest", "Enter regression test mode, which uses a special " | true, OptionsCategory::CHAINPARAMS); | ||||
"chain in which blocks can be solved instantly. " | gArgs.AddArg("-testnet", _("Use the test chain"), false, | ||||
"This is intended for regression testing tools and app " | OptionsCategory::CHAINPARAMS); | ||||
"development."); | |||||
} | |||||
} | } | ||||
/** | /** | ||||
* Main network | * Main network | ||||
*/ | */ | ||||
class CBaseMainParams : public CBaseChainParams { | class CBaseMainParams : public CBaseChainParams { | ||||
public: | public: | ||||
CBaseMainParams() { nRPCPort = 8332; } | CBaseMainParams() { nRPCPort = 8332; } | ||||
▲ Show 20 Lines • Show All 48 Lines • Show Last 20 Lines |