mirror of
https://github.com/bitcoinj/bitcoinj.git
synced 2025-01-18 21:32:35 +01:00
TransactionBroadcast: add awaitSent()
method
This just returns the used internally (and therefore tested) `sentFuture`.
This commit is contained in:
parent
bce7b11038
commit
2e3e6d4485
@ -217,6 +217,15 @@ public class TransactionBroadcast {
|
||||
.thenApply(tx -> this);
|
||||
}
|
||||
|
||||
/**
|
||||
* Wait for confirmation the transaction has been sent to a remote peer. (Or at least buffered to be sent to
|
||||
* a peer.)
|
||||
* @return A future that completes when the message has been relayed by the appropriate number of remote peers
|
||||
*/
|
||||
public CompletableFuture<TransactionBroadcast> awaitSent() {
|
||||
return sentFuture;
|
||||
}
|
||||
|
||||
/**
|
||||
* If you migrate to {@link #broadcastAndAwaitRelay()} and need a {@link CompletableFuture} that returns
|
||||
* {@link Transaction} you can use:
|
||||
|
Loading…
Reference in New Issue
Block a user