nopara73 / HBitcoin

Privacy focused Bitcoin library on top of NBitcoin for .NET Core.
MIT License
26 stars 11 forks source link

Act on @dangershony's review #4

Closed nopara73 closed 7 years ago

nopara73 commented 7 years ago

After: https://github.com/nopara73/HBitcoin/issues/6

HI Adam, I had a quick glance at the HBitcoin code and want to offer a small review.
I noticed you have a WalletJob class that combines logic with other aspects of an SPV, for example you would not want to have a BlockPuller or NodesGroup in an  IWallet type, assuming the wallet needs to hold user addresses and transactions, instead you would have the wallet have two interfaces 
IWallet.AcceptBlock
IWallet.AcceptTransaction (for pending trx)
The IWallet will have to take a ConcurrentChain in the constructor so you can handle and detect reorgs.
And it should not know about anything else, this is then a reusable object.
The puller will be a separate component all together.

I only had a quick glance so might got it completely wrong (edited)

@dangershony

dangershony commented 7 years ago

@bokobza