Changeset View
Changeset View
Standalone View
Standalone View
chronik/chronik-bridge/src/ffi.rs
Show First 20 Lines • Show All 46 Lines • ▼ Show 20 Lines | pub struct Block { | ||||
/// This can be used to later slice out transactions, so we don't have | /// This can be used to later slice out transactions, so we don't have | ||||
/// to index txs twice. | /// to index txs twice. | ||||
pub file_num: u32, | pub file_num: u32, | ||||
/// Position of the block within the block file, starting at the block | /// Position of the block within the block file, starting at the block | ||||
/// header. | /// header. | ||||
pub data_pos: u32, | pub data_pos: u32, | ||||
/// Position of the undo data within the undo file. | /// Position of the undo data within the undo file. | ||||
pub undo_pos: u32, | pub undo_pos: u32, | ||||
/// Serialized size of the block | |||||
pub size: u64, | |||||
/// Txs of this block, including positions within the block/undo files. | /// Txs of this block, including positions within the block/undo files. | ||||
pub txs: Vec<BlockTx>, | pub txs: Vec<BlockTx>, | ||||
} | } | ||||
/// Tx in a block | /// Tx in a block | ||||
#[derive(Clone, Debug, Default, Eq, PartialEq)] | #[derive(Clone, Debug, Default, Eq, PartialEq)] | ||||
pub struct BlockTx { | pub struct BlockTx { | ||||
/// Tx (without disk data) | /// Tx (without disk data) | ||||
▲ Show 20 Lines • Show All 182 Lines • Show Last 20 Lines |