Bitcoin ABC 0.26.3
P2P Digital Currency
Loading...
Searching...
No Matches
mempool_persist_args.cpp
Go to the documentation of this file.
1// Copyright (c) 2022 The Bitcoin Core developers
2// Distributed under the MIT software license, see the accompanying
3// file COPYING or http://www.opensource.org/licenses/mit-license.php.
4
6
7#include <common/args.h>
8#include <util/fs.h>
9#include <validation.h>
10
11namespace node {
12
14 return argsman.GetBoolArg("-persistmempool", DEFAULT_PERSIST_MEMPOOL);
15}
16
18 return argsman.GetDataDirNet() / "mempool.dat";
19}
20
21} // namespace node
Path class wrapper to block calls to the fs::path(std::string) implicit constructor and the fs::path:...
Definition fs.h:30
Definition init.h:28
fs::path MempoolPath(const ArgsManager &argsman)
bool ShouldPersistMempool(const ArgsManager &argsman)
static constexpr bool DEFAULT_PERSIST_MEMPOOL
Default for -persistmempool, indicating whether the node should attempt to automatically load the mem...
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