Struct bitcoin::util::bip158::BlockFilterWriter
source · pub struct BlockFilterWriter<'a> { /* private fields */ }
Expand description
Compiles and writes a block filter
Implementations§
source§impl<'a> BlockFilterWriter<'a>
impl<'a> BlockFilterWriter<'a>
sourcepub fn new(writer: &'a mut dyn Write, block: &'a Block) -> BlockFilterWriter<'a>
pub fn new(writer: &'a mut dyn Write, block: &'a Block) -> BlockFilterWriter<'a>
Create a block filter writer
sourcepub fn add_output_scripts(&mut self)
pub fn add_output_scripts(&mut self)
Add output scripts of the block - excluding OP_RETURN scripts
sourcepub fn add_input_scripts<M>(&mut self, script_for_coin: M) -> Result<(), Error>where
M: Fn(&OutPoint) -> Result<Script, Error>,
pub fn add_input_scripts<M>(&mut self, script_for_coin: M) -> Result<(), Error>where M: Fn(&OutPoint) -> Result<Script, Error>,
Add consumed output scripts of a block to filter
sourcepub fn add_element(&mut self, data: &[u8])
pub fn add_element(&mut self, data: &[u8])
Add arbitrary element to a filter
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for BlockFilterWriter<'a>
impl<'a> !Send for BlockFilterWriter<'a>
impl<'a> !Sync for BlockFilterWriter<'a>
impl<'a> Unpin for BlockFilterWriter<'a>
impl<'a> !UnwindSafe for BlockFilterWriter<'a>
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more