//Block Constructor. public Block(String data, String previousHash) { this.data = data; this.previousHash = previousHash; this.timeStamp = Datetime.GetTime(); this.hash = CalculateHash(); }
public Block(int height, string previousHash, Transaction transaction, string creator) { this.height = height; this.previousHash = previousHash; this.timeStamp = Datetime.GetTime(); this.transaction = transaction; this.hash = CalculateHash(); this.Creator = creator; }