Subject: Re: [Bitcoin-development] overall bitcoin client code quality

From: Mike Hearn <[email-masked]>
Date: Wed, 13 Jul 2011 13:50:38 +0200

For what it's worth, BitCoinJ has a NetworkParameters abstraction that
does what you suggest (groups all the constants together):

  http://code.google.com/p/bitcoinj/source/browse/trunk/src/com/google/bitcoin/core/NetworkParameters.java

It exists primarily to make unit testing easier. In the test suite, we
often build small chains and other structures. We do this by using a
NetworkParameters that has the easiest difficulty possible. It means
you can solve blocks in a few attempts, easily fast enough to build
test chains of any length you like.

I suspect that as the test suite expands, a similar abstraction will
be introduced to the Satoshi client.