Crate bitcoin_units

Source
Expand description

Rust Bitcoin units library

This library provides basic types used by the Rust Bitcoin ecosystem.

Modules§

amount
Bitcoin amounts.
blockalloc
Block height and interval types.
fee_ratealloc
Implements FeeRate and assoctiated features.
locktimealloc
Provides absolute and relative locktimes.
parsealloc
Parsing utilities.
weightalloc
Implements Weight and associated features.

Macros§

impl_parse_stralloc
Implements standard parsing traits for $type by calling into $inner_fn.
impl_parse_str_from_int_infalliblealloc
Implements FromStr and TryFrom<{&str, String, Box<str>}> for $to using parse::int, mapping the output using infallible conversion function fn.
impl_tryfrom_stralloc
Implements TryFrom<$from> for $to.
impl_tryfrom_str_from_int_infalliblealloc
Implements TryFrom<$from> for $to using parse::int, mapping the output using infallible conversion function fn.

Structs§

Amount
An amount.
BlockHeightalloc
The block height, zero denotes the genesis block.
BlockIntervalalloc
The block interval.
FeeRatealloc
Represents fee rate.
SignedAmount
A signed amount.
Weightalloc
Represents block weight - the weight of a transaction or block.