A toy project that maintains a ledger of account (like a bank's ledger). Takes a csv file path argument, processes the rows as transactions into the Ledger, then outputs the final state of the accounts. Invalid csv rows are ignored. Errors that occur from processing are currently ignored, but can be printed for useful messages.
cargo run -- transactions.csv > out.csv
type, client, tx, amount
deposit, 1, 1, 1.0
withdrawal, 1, 2, 1.0
deposit, 2, 3, 1.0
withdrawal, 2, 4, 1.0
dispute, 2, 4
resolve, 2, 4
deposit
- Putting funds into an accountwithdrawal
- Taking funds out of an accountdispute
- Challenge a transaction by IDresolve
- Concludes a dispute by giving back held fundschargeback
- Reverses a disputed transaction and locks account