Пример #1
0
 /** Returns a {@link Wallet.SendRequest} suitable for broadcasting to the network. */
 public Wallet.SendRequest getSendRequest() {
   Transaction tx = new Transaction(params);
   for (Protos.Output output : paymentDetails.getOutputsList())
     tx.addOutput(
         new TransactionOutput(
             params,
             tx,
             BigInteger.valueOf(output.getAmount()),
             output.getScript().toByteArray()));
   return Wallet.SendRequest.forTx(tx);
 }
 public SendRequest toSendRequest() {
   final Transaction transaction = new Transaction(Constants.NETWORK_PARAMETERS);
   for (final PaymentIntent.Output output : outputs)
     transaction.addOutput(output.amount, output.script);
   return SendRequest.forTx(transaction);
 }