/// <summary>
        /// Deploys the contract.  <para/>
        /// </summary>

        /// <param name = "rpcClient">The RPC client to be used for this contract instance.</param>
        /// <param name = "defaultFromAccount">If null then the first account returned by eth_accounts will be used.</param>
        /// <returns>An contract instance pointed at the deployed contract address.</returns>
        public static async Task <aclContract> Deploy(Meadow.JsonRpc.Client.IJsonRpcClient rpcClient, Meadow.JsonRpc.Types.TransactionParams transactionParams = null, Meadow.Core.EthTypes.Address?defaultFromAccount = null)
        {
            transactionParams      = transactionParams ?? new Meadow.JsonRpc.Types.TransactionParams();
            defaultFromAccount     = defaultFromAccount ?? transactionParams.From ?? (await rpcClient.Accounts())[0];
            transactionParams.From = transactionParams.From ?? defaultFromAccount;
            var encodedParams = Array.Empty <byte>();
            var contractAddr  = await ContractFactory.Deploy(rpcClient, BYTECODE_BYTES.Value, transactionParams, encodedParams);

            return(new aclContract(rpcClient, contractAddr, defaultFromAccount.Value));
        }
        /// <summary>
        /// Deploys the contract.  <para/>
        /// </summary>

        /// <param name = "rpcClient">The RPC client to be used for this contract instance.</param>
        /// <param name = "defaultFromAccount">If null then the first account returned by eth_accounts will be used.</param>
        /// <returns>An contract instance pointed at the deployed contract address.</returns>
        public static ContractDeployer <aclContract> New(Meadow.JsonRpc.Client.IJsonRpcClient rpcClient, Meadow.JsonRpc.Types.TransactionParams transactionParams = null, Meadow.Core.EthTypes.Address?defaultFromAccount = null)
        {
            var encodedParams = Array.Empty <byte>();

            return(new ContractDeployer <aclContract>(rpcClient, BYTECODE_BYTES.Value, transactionParams, defaultFromAccount, encodedParams));
        }
 private aclContract(Meadow.JsonRpc.Client.IJsonRpcClient rpcClient, Meadow.Core.EthTypes.Address address, Meadow.Core.EthTypes.Address defaultFromAccount) : base(rpcClient, address, defaultFromAccount)
 {
     Meadow.Contract.EventLogUtil.RegisterDeployedContractEventTypes(address.GetHexString(hexPrefix: true), typeof(solidity_vscode_unit_test.aclContract.LogAccess));
 }
 public static async Task <aclContract> At(Meadow.JsonRpc.Client.IJsonRpcClient rpcClient, Meadow.Core.EthTypes.Address address, Meadow.Core.EthTypes.Address?defaultFromAccount = null)
 {
     defaultFromAccount = defaultFromAccount ?? (await rpcClient.Accounts())[0];
     return(new aclContract(rpcClient, address, defaultFromAccount.Value));
 }
 private HelloWorld(Meadow.JsonRpc.Client.IJsonRpcClient rpcClient, Meadow.Core.EthTypes.Address address, Meadow.Core.EthTypes.Address defaultFromAccount) : base(rpcClient, address, defaultFromAccount)
 {
     Meadow.Contract.EventLogUtil.RegisterDeployedContractEventTypes(address.GetHexString(hexPrefix: true), typeof(TokenContract.HelloWorld.HelloEvent));
 }
        /// <summary>
        /// Deploys the contract.  <para/>
        /// </summary>
        /// <param name = "total"><c>uint256</c></param>
        /// <param name = "rpcClient">The RPC client to be used for this contract instance.</param>
        /// <param name = "defaultFromAccount">If null then the first account returned by eth_accounts will be used.</param>
        /// <returns>An contract instance pointed at the deployed contract address.</returns>
        public static ContractDeployer <ERC20Basic> New(Meadow.Core.EthTypes.UInt256 total, Meadow.JsonRpc.Client.IJsonRpcClient rpcClient, Meadow.JsonRpc.Types.TransactionParams transactionParams = null, Meadow.Core.EthTypes.Address?defaultFromAccount = null)
        {
            var encodedParams = Meadow.Core.AbiEncoding.EncoderUtil.Encode(EncoderFactory.LoadEncoder("uint256", total));

            return(new ContractDeployer <ERC20Basic>(rpcClient, BYTECODE_BYTES.Value, transactionParams, defaultFromAccount, encodedParams));
        }
        /// <summary>
        /// Deploys the contract.  <para/>
        /// </summary>
        /// <param name = "total"><c>uint256</c></param>
        /// <param name = "rpcClient">The RPC client to be used for this contract instance.</param>
        /// <param name = "defaultFromAccount">If null then the first account returned by eth_accounts will be used.</param>
        /// <returns>An contract instance pointed at the deployed contract address.</returns>
        public static async Task <ERC20Basic> Deploy(Meadow.Core.EthTypes.UInt256 total, Meadow.JsonRpc.Client.IJsonRpcClient rpcClient, Meadow.JsonRpc.Types.TransactionParams transactionParams = null, Meadow.Core.EthTypes.Address?defaultFromAccount = null)
        {
            transactionParams      = transactionParams ?? new Meadow.JsonRpc.Types.TransactionParams();
            defaultFromAccount     = defaultFromAccount ?? transactionParams.From ?? (await rpcClient.Accounts())[0];
            transactionParams.From = transactionParams.From ?? defaultFromAccount;
            var encodedParams = Meadow.Core.AbiEncoding.EncoderUtil.Encode(EncoderFactory.LoadEncoder("uint256", total));
            var contractAddr  = await ContractFactory.Deploy(rpcClient, BYTECODE_BYTES.Value, transactionParams, encodedParams);

            return(new ERC20Basic(rpcClient, contractAddr, defaultFromAccount.Value));
        }
 private ERC20Basic(Meadow.JsonRpc.Client.IJsonRpcClient rpcClient, Meadow.Core.EthTypes.Address address, Meadow.Core.EthTypes.Address defaultFromAccount) : base(rpcClient, address, defaultFromAccount)
 {
     Meadow.Contract.EventLogUtil.RegisterDeployedContractEventTypes(address.GetHexString(hexPrefix: true), typeof(TokenContract.ERC20Basic.Approval), typeof(TokenContract.ERC20Basic.Transfer));
 }
 private SafeMath(Meadow.JsonRpc.Client.IJsonRpcClient rpcClient, Meadow.Core.EthTypes.Address address, Meadow.Core.EthTypes.Address defaultFromAccount) : base(rpcClient, address, defaultFromAccount)
 {
     Meadow.Contract.EventLogUtil.RegisterDeployedContractEventTypes(address.GetHexString(hexPrefix: true));
 }