예제 #1
0
        public BlockChain()
        {
            var blockPool = BlockPool.Get();

            var zeroBlock = new Block()
            {
                Index    = 0,
                Date     = DateTime.Now,
                PrevHash = ""
            };

            zeroBlock.Txs.Add(new Transaction()
            {
                From   = "",
                To     = "root",
                Amount = 10000
            });

            blockPool.SetGetBlock(zeroBlock);
        }
예제 #2
0
 public static BlockPool Get() => Instance ?? (Instance = new BlockPool());