Page MenuHomePhabricator

[Chronik] Refactor `Group`, add `input_members` and `output_members`
ClosedPublic

Authored by tobias_ruck on Apr 14 2023, 12:12.

Details

Summary

While for the group history, it's fine to have all members be in one iterator with both inputs and outputs, for the UTXOs, we have to know which input/output a member belongs to.

For this, we add input_members and output_members, which return iterators of MemberItem, which add an idx to members so we know which input/output it's associated with.

We add tx_members_for_group so we retain the convenience of having one function returning all the members for group history.

We also change the Iter type of the existing groups to Vec, which also implements IntoIterator. This makes the code more simple and has been an oversight before.

Depends on D13704.

Test Plan

ninja check-crates && ninja check-functional

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable