Page MenuHomePhabricator

blockdb.h
No OneTemporary

blockdb.h

// Copyright 2020 The Bitcoin developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#ifndef BITCOIN_BLOCKDB_H
#define BITCOIN_BLOCKDB_H
#include <flatfile.h>
namespace Consensus {
struct Params;
}
class CBlock;
class CBlockIndex;
/** The pre-allocation chunk size for blk?????.dat files (since 0.8) */
static constexpr unsigned int BLOCKFILE_CHUNK_SIZE = 0x1000000; // 16 MiB
/** The pre-allocation chunk size for rev?????.dat files (since 0.8) */
static const unsigned int UNDOFILE_CHUNK_SIZE = 0x100000; // 1 MiB
FlatFileSeq BlockFileSeq();
FlatFileSeq UndoFileSeq();
FILE *OpenUndoFile(const FlatFilePos &pos, bool fReadOnly = false);
/**
* Translation to a filesystem path.
*/
fs::path GetBlockPosFilename(const FlatFilePos &pos);
/**
* Open a block file (blk?????.dat).
*/
FILE *OpenBlockFile(const FlatFilePos &pos, bool fReadOnly = false);
#endif // BITCOIN_BLOCKDB_H

File Metadata

Mime Type
text/x-c++
Expires
Sat, Nov 23, 10:04 (1 d, 5 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
4515967
Default Alt Text
blockdb.h (984 B)

Event Timeline