Exemple #1
0
 /// <summary>
 /// Block Chain constructor
 /// Both creates the chain and the genesis block
 /// </summary>
 public BlockChainObj(P2PClient client)
 {
     this.client = client;
     client.OnMessageReceived += MessageReceivedFromClient;
     chain           = new List <Block>();
     transactionPool = new TransactionPool();
     chain.Add(CreateGenesisBlock());
 }
Exemple #2
0
 /// <summary>
 /// Block Chain constructor
 /// Both creates the chain and the genesis block
 /// </summary>
 public Miner(P2PClient client)
 {
     this.client = client;
     client.OnMessageReceived += MessageReceivedFromClient;
     transactionPool           = new TransactionPool();
 }