Package org.consensusj.bitcoin.rx.zeromq
Class RxBitcoinZmqBinaryService
java.lang.Object
org.consensusj.bitcoin.rx.zeromq.RxBitcoinZmqBinaryService
- All Implemented Interfaces:
Closeable
,AutoCloseable
,RxBlockchainBinaryService
- Direct Known Subclasses:
RxBitcoinZmqService
public class RxBitcoinZmqBinaryService
extends Object
implements RxBlockchainBinaryService, Closeable
Service to listen for ZMQ messages from multiple TCP ports. Uses Bitcoin Core JSON-RPC to find
the TCP address of the required services.
TODO: Support using all topics, notjust `rawblock` and `rawtx`.
-
Field Summary
-
Constructor Summary
ConstructorDescriptionRxBitcoinZmqBinaryService
(org.bitcoinj.base.Network network, URI rpcUri, String rpcUser, String rpcPassword) -
Method Summary
Modifier and TypeMethodDescriptionorg.reactivestreams.Publisher
<byte[]> org.reactivestreams.Publisher
<byte[]> void
close()
org.reactivestreams.Publisher
<byte[]> org.reactivestreams.Publisher
<byte[]>
-
Field Details
-
client
-
-
Constructor Details
-
RxBitcoinZmqBinaryService
public RxBitcoinZmqBinaryService(org.bitcoinj.base.Network network, URI rpcUri, String rpcUser, String rpcPassword) -
RxBitcoinZmqBinaryService
-
-
Method Details
-
transactionBinaryPublisher
- Specified by:
transactionBinaryPublisher
in interfaceRxBlockchainBinaryService
-
transactionHashBinaryPublisher
- Specified by:
transactionHashBinaryPublisher
in interfaceRxBlockchainBinaryService
-
blockBinaryPublisher
- Specified by:
blockBinaryPublisher
in interfaceRxBlockchainBinaryService
-
blockHashBinaryPublisher
- Specified by:
blockHashBinaryPublisher
in interfaceRxBlockchainBinaryService
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
-