Esempio n. 1
0
 public string GetAllBlocks(int index)
 {
     Model.Block block = null;
     if (index < DependencyManager.BlockMiner.Blockchain.Count)
     {
         block = DependencyManager.BlockMiner.Blockchain[index];
     }
     return(JsonConvert.SerializeObject(block));
 }
Esempio n. 2
0
 public string GetAllBlocks(int blocknum)
 {
     Model.Block block = null;
     if (blocknum < DependencyManager.BlockMiner.Blockchain.Count)
     {
         block = DependencyManager.BlockMiner.Blockchain[blocknum];
     }
     return(JsonConvert.SerializeObject(block, Formatting.Indented));
 }