[Chronik] Add IndexTx and prepare_indexed_txs
Summary:
This nicely bundles data we need for indexing tx history, UTXOs etc. without having to recompute things like tx_num, is_coinbase etc. We use this in GroupHistoryWriter.
Also compute input_nums in prepare_indexed_txs, which atm is unused but will be necessary for indexing UTXOs. In the future, this function would also be a place where optimizations such as caching or multi_get could be employed to speed up the indexer.
Test Plan: ninja check-crates && ninja check-functional
Reviewers: Fabien, #bitcoin_abc
Reviewed By: Fabien, #bitcoin_abc
Differential Revision: https://reviews.bitcoinabc.org/D13704