Add commenting around JSON error codes
[bitcoinplatinum.git] / src / init.h
blob8222794374781c491e4557ebaf52523b1ccc726f
1 // Copyright (c) 2009-2010 Satoshi Nakamoto
2 // Copyright (c) 2009-2016 The Bitcoin Core developers
3 // Distributed under the MIT software license, see the accompanying
4 // file COPYING or http://www.opensource.org/licenses/mit-license.php.
6 #ifndef BITCOIN_INIT_H
7 #define BITCOIN_INIT_H
9 #include <string>
11 class CScheduler;
12 class CWallet;
14 namespace boost
16 class thread_group;
17 } // namespace boost
19 void StartShutdown();
20 bool ShutdownRequested();
21 /** Interrupt threads */
22 void Interrupt(boost::thread_group& threadGroup);
23 void Shutdown();
24 //!Initialize the logging infrastructure
25 void InitLogging();
26 //!Parameter interaction: change current parameters depending on various rules
27 void InitParameterInteraction();
29 /** Initialize bitcoin core: Basic context setup.
30 * @note This can be done before daemonization.
31 * @pre Parameters should be parsed and config file should be read.
33 bool AppInitBasicSetup();
34 /**
35 * Initialization: parameter interaction.
36 * @note This can be done before daemonization.
37 * @pre Parameters should be parsed and config file should be read, AppInitBasicSetup should have been called.
39 bool AppInitParameterInteraction();
40 /**
41 * Initialization sanity checks: ecc init, sanity checks, dir lock.
42 * @note This can be done before daemonization.
43 * @pre Parameters should be parsed and config file should be read, AppInitParameterInteraction should have been called.
45 bool AppInitSanityChecks();
46 /**
47 * Bitcoin core main initialization.
48 * @note This should only be done after daemonization.
49 * @pre Parameters should be parsed and config file should be read, AppInitSanityChecks should have been called.
51 bool AppInitMain(boost::thread_group& threadGroup, CScheduler& scheduler);
53 /** The help message mode determines what help message to show */
54 enum HelpMessageMode {
55 HMM_BITCOIND,
56 HMM_BITCOIN_QT
59 /** Help for options shared between UI and daemon (for -help) */
60 std::string HelpMessage(HelpMessageMode mode);
61 /** Returns licensing information (for -version) */
62 std::string LicenseInfo();
64 #endif // BITCOIN_INIT_H