コード例 #1
0
        public SignRawTransactionWithWalletResponse SignRawTransactionWithWallet(SignRawTransactionWithWalletRequest request)
        {
            #region default values

            if (request.Inputs.Count == 0)
            {
                request.Inputs = null;
            }

            if (string.IsNullOrWhiteSpace(request.SigHashType))
            {
                request.SigHashType = SigHashType.All;
            }

            #endregion

            return(_rpcConnector.MakeRequest <SignRawTransactionWithWalletResponse>(RpcMethods.signrawtransactionwithwallet, request.RawTransactionHex, request.Inputs, request.SigHashType));
        }
コード例 #2
0
        public Task <SignRawTransactionWithWalletResponse> SignRawTransactionWithWalletAsync(SignRawTransactionWithWalletRequest request, CancellationToken cancellationToken)
        {
            #region default values

            if (request.Inputs.Count == 0)
            {
                request.Inputs = null;
            }

            if (string.IsNullOrWhiteSpace(request.SigHashType))
            {
                request.SigHashType = SigHashType.All;
            }

            #endregion

            return(_asyncRpcConnector.MakeRequestAsync <SignRawTransactionWithWalletResponse>(RpcMethods.signrawtransactionwithwallet, cancellationToken, request.RawTransactionHex, request.Inputs, request.SigHashType));
        }