Esempio n. 1
0
        public static async Task <TheOtherService> DeployContractAndGetServiceAsync(Web3 web3, TheOtherDeployment theOtherDeployment, CancellationToken cancellationToken = default(CancellationToken))
        {
            var receipt = await DeployContractAndWaitForReceiptAsync(web3, theOtherDeployment, cancellationToken);

            return(new TheOtherService(web3, receipt.ContractAddress));
        }
Esempio n. 2
0
 public static Task <TransactionReceipt> DeployContractAndWaitForReceiptAsync(Web3 web3, TheOtherDeployment theOtherDeployment, CancellationToken cancellationToken = default(CancellationToken))
 {
     return(web3.Eth.GetContractDeploymentHandler <TheOtherDeployment>().SendRequestAndWaitForReceiptAsync(theOtherDeployment, cancellationToken));
 }
Esempio n. 3
0
 public static Task <string> DeployContractAsync(Web3 web3, TheOtherDeployment theOtherDeployment)
 {
     return(web3.Eth.GetContractDeploymentHandler <TheOtherDeployment>().SendRequestAsync(theOtherDeployment));
 }
Esempio n. 4
0
        public static async Task <TheOtherService> DeployContractAndGetServiceAsync(Web3 web3, TheOtherDeployment theOtherDeployment, CancellationTokenSource cancellationTokenSource = null)
        {
            var receipt = await DeployContractAndWaitForReceiptAsync(web3, theOtherDeployment, cancellationTokenSource).ConfigureAwait(false);

            return(new TheOtherService(web3, receipt.ContractAddress));
        }