btck::Block

Owning wrapper over a btck_Block, a full block with its transactions.

Synopsis

Declared in <kernel/bitcoinkernel_wrapper.h>

class Block
    : public Handle<btck_Block, btck_block_copy, btck_block_destroy>

Base Classes

NameDescription
Handle<btck_Block, btck_block_copy, btck_block_destroy>Owning RAII handle for a copyable C object of type CType.

Member Functions

NameDescription
Block [constructor]Constructors
operator= Assignment operators
Check Runs the requested consensus checks on the block.
CountTransactions Returns the number of transactions in the block.
GetHash Returns the block hash.
GetHeader Returns the block header.
GetTransaction Returns a single transaction by index.
ToBytes Serializes the block to its raw bytes.
Transactions Returns a range over all transactions in the block.
get Returns the owned C handle.

Protected Data Members

NameDescription
m_ptr The owned C handle.