Bitcoin ABC 0.26.3
P2P Digital Currency
Loading...
Searching...
No Matches
shutdown.h
Go to the documentation of this file.
1// Copyright (c) 2009-2010 Satoshi Nakamoto
2// Copyright (c) 2009-2018 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.
5
6#ifndef BITCOIN_SHUTDOWN_H
7#define BITCOIN_SHUTDOWN_H
8
9#include <util/translation.h> // For bilingual_str
10
12bool AbortNode(const std::string &strMessage,
14
21
23void StartShutdown();
24
30void AbortShutdown();
31
34
39void WaitForShutdown();
40
41#endif // BITCOIN_SHUTDOWN_H
T GetRand(T nMax=std::numeric_limits< T >::max()) noexcept
Generate a uniform random integer of type T in the range [0..nMax) nMax defaults to std::numeric_limi...
Definition random.h:85
void WaitForShutdown()
Wait for StartShutdown to be called in any thread.
Definition shutdown.cpp:89
bool ShutdownRequested()
Returns true if a shutdown is requested, false otherwise.
Definition shutdown.cpp:85
bool InitShutdownState()
Initialize shutdown state.
Definition shutdown.cpp:43
void StartShutdown()
Request shutdown of the application.
Definition shutdown.cpp:55
bool AbortNode(const std::string &strMessage, bilingual_str user_message=bilingual_str{})
Abort with a message.
Definition shutdown.cpp:20
void AbortShutdown()
Clear shutdown flag.
Definition shutdown.cpp:76
Bilingual messages:
Definition translation.h:17