[bdk_chain_redesign] Add apply_additions to IndexedTxGraph

* Get mutable index from `IndexedChainGraph`.
* Also add `apply_additions` method to `TxIndex` trait.
This commit is contained in:
志宇
2023-03-27 15:36:37 +08:00
parent 6cbb18d409
commit d0a2aa83be
4 changed files with 26 additions and 0 deletions

View File

@@ -68,6 +68,10 @@ impl<I: Clone + Ord + 'static> TxIndex for SpkTxOutIndex<I> {
self.scan(tx)
}
fn apply_additions(&mut self, _additions: Self::Additions) {
// This applies nothing.
}
fn is_tx_relevant(&self, tx: &Transaction) -> bool {
self.is_relevant(tx)
}