crate::ix!();
pub const DEFAULT_STOPAFTERBLOCKIMPORT: bool = false;
pub const BLOCKFILE_CHUNK_SIZE: u32 = 0x1000000;
pub const UNDOFILE_CHUNK_SIZE: u32 = 0x100000;
pub const MAX_BLOCKFILE_SIZE: u32 = 0x8000000;
pub fn is_block_pruned(pblockindex: *const BlockIndex) -> bool {
todo!();
}
pub fn cleanup_block_rev_files() {
todo!();
}
pub fn get_block_file_info(n: usize) -> *mut BlockFileInfo {
todo!();
}
pub fn undo_write_to_disk(
blockundo: &BlockUndo,
pos: &mut FlatFilePos,
hash_block: &u256,
message_start: &message_header::MessageStartChars) -> bool {
todo!();
}
pub fn undo_read_from_disk(
blockundo: &mut BlockUndo,
pindex: *const BlockIndex) -> bool {
todo!();
}
pub fn flush_undo_file(
block_file: i32,
finalize: Option<bool>) {
let finalize: bool = finalize.unwrap_or(false);
todo!();
}
pub fn flush_block_file(
finalize: Option<bool>,
finalize_undo: Option<bool>) {
let finalize: bool = finalize.unwrap_or(false);
let finalize_undo: bool = finalize_undo.unwrap_or(false);
todo!();
}
pub fn calculate_current_usage() -> u64 {
todo!();
}
pub fn unlink_pruned_files(set_files_to_prune: &HashSet<i32>) {
todo!();
}
pub fn block_file_seq() -> FlatFileSeq {
todo!();
}
pub fn undo_file_seq() -> FlatFileSeq {
todo!();
}
pub fn open_block_file(
pos: &FlatFilePos,
read_only: Option<bool>) -> *mut libc::FILE {
let read_only = read_only.unwrap_or(false);
todo!();
}
pub fn open_undo_file(
pos: &FlatFilePos,
read_only: Option<bool>) -> *mut libc::FILE {
let read_only: bool = read_only.unwrap_or(false);
todo!();
}
pub fn get_block_pos_filename(pos: &FlatFilePos) -> Box<Path> {
todo!();
}
pub fn find_block_pos(
pos: &mut FlatFilePos,
n_add_size: u32,
n_height: u32,
active_chain: &mut Chain,
n_time: u64,
known: Option<bool>) -> bool {
let known: bool = known.unwrap_or(false);
todo!();
}
pub fn find_undo_pos(
state: &mut BlockValidationState,
n_file: i32,
pos: &mut FlatFilePos,
n_add_size: u32) -> bool {
todo!();
}
pub fn write_block_to_disk(
block: &Block,
pos: &mut FlatFilePos,
message_start: &message_header::MessageStartChars) -> bool {
todo!();
}
pub fn write_undo_data_for_block(
blockundo: &BlockUndo,
state: &mut BlockValidationState,
pindex: *mut BlockIndex,
chainparams: &ChainParams) -> bool {
todo!();
}
pub fn save_block_to_disk(
block: &Block,
n_height: i32,
active_chain: &mut Chain,
chainparams: &ChainParams,
dbp: *const FlatFilePos) -> FlatFilePos {
todo!();
}
pub struct ImportingNow { }
impl Default for ImportingNow {
fn default() -> Self {
todo!();
}
}
impl Drop for ImportingNow {
fn drop(&mut self) {
todo!();
}
}
pub fn thread_import(
chainman: &mut ChainstateManager,
import_files: Vec<Box<Path>>,
args: &ArgsManager) {
todo!();
}