public Address(Network network, byte[] pubKeyHash) { if(network == null ) throw new ArgumentNullException("network"); if(pubKeyHash == null) throw new ArgumentNullException("pubKeyHash"); //if (pubKeyHash.Length != 32) // throw new ArgumentException("pubKeyHash must be a 32 byte length array"); Network = network; _pubKeyHash = pubKeyHash; }
private static Network CreateMainNet() { var network = new Network(); network._prefixType = new Dictionary<DataTypePrefix, byte[]> { { DataTypePrefix.PublicKeyHash, new byte[] { 0x00 } }, { DataTypePrefix.ScriptHash, new byte[] { 0x05 } }, { DataTypePrefix.PrivateKey, new byte[] { 0x80 } }, { DataTypePrefix.ExtPublicKey, new byte[] { 0x04, 0x88, 0xb2, 0x1e } } }; network._rewardHalvingBlocks = 210 * 1000; // ~4 years network._initialReward = 50*100*1000*1000L; return network; }