Package org.web3j.protocol.core
Class JsonRpc2_0Web3j
- java.lang.Object
-
- org.web3j.protocol.core.JsonRpc2_0Web3j
-
-
Field Summary
Fields Modifier and Type Field Description static intDEFAULT_BLOCK_TIMEprotected Web3jServiceweb3jService
-
Constructor Summary
Constructors Constructor Description JsonRpc2_0Web3j(Web3jService web3jService)JsonRpc2_0Web3j(Web3jService web3jService, long pollingInterval, java.util.concurrent.ScheduledExecutorService scheduledExecutorService)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Request<?,BooleanResponse>adminAddPeer(java.lang.String url)Request<?,AdminDataDir>adminDataDir()Request<?,AdminNodeInfo>adminNodeInfo()Request<?,AdminPeers>adminPeers()Request<?,BooleanResponse>adminRemovePeer(java.lang.String url)io.reactivex.Flowable<EthBlock>blockFlowable(boolean fullTransactionObjects)Create anFlowableinstance that emits newly created blocks on the blockchain.Request<?,DbGetHex>dbGetHex(java.lang.String databaseName, java.lang.String keyName)Request<?,DbGetString>dbGetString(java.lang.String databaseName, java.lang.String keyName)Request<?,DbPutHex>dbPutHex(java.lang.String databaseName, java.lang.String keyName, java.lang.String dataToStore)Request<?,DbPutString>dbPutString(java.lang.String databaseName, java.lang.String keyName, java.lang.String stringToStore)Request<?,EthAccounts>ethAccounts()io.reactivex.Flowable<java.lang.String>ethBlockHashFlowable()Create an Flowable to emit block hashes.Request<?,EthBlockNumber>ethBlockNumber()Request<?,EthCall>ethCall(Transaction transaction, DefaultBlockParameter defaultBlockParameter)Request<?,EthChainId>ethChainId()Request<?,EthCoinbase>ethCoinbase()Request<?,EthCompileLLL>ethCompileLLL(java.lang.String sourceCode)Request<?,EthCompileSerpent>ethCompileSerpent(java.lang.String sourceCode)Request<?,EthCompileSolidity>ethCompileSolidity(java.lang.String sourceCode)Request<?,EthEstimateGas>ethEstimateGas(Transaction transaction)Request<?,EthGasPrice>ethGasPrice()Request<?,EthGetBalance>ethGetBalance(java.lang.String address, DefaultBlockParameter defaultBlockParameter)Request<?,EthBlock>ethGetBlockByHash(java.lang.String blockHash, boolean returnFullTransactionObjects)Request<?,EthBlock>ethGetBlockByNumber(DefaultBlockParameter defaultBlockParameter, boolean returnFullTransactionObjects)Request<?,EthGetBlockTransactionCountByHash>ethGetBlockTransactionCountByHash(java.lang.String blockHash)Request<?,EthGetBlockTransactionCountByNumber>ethGetBlockTransactionCountByNumber(DefaultBlockParameter defaultBlockParameter)Request<?,EthGetCode>ethGetCode(java.lang.String address, DefaultBlockParameter defaultBlockParameter)Request<?,EthGetCompilers>ethGetCompilers()Request<?,EthLog>ethGetFilterChanges(java.math.BigInteger filterId)Request<?,EthLog>ethGetFilterLogs(java.math.BigInteger filterId)Request<?,EthLog>ethGetLogs(EthFilter ethFilter)Request<?,EthGetStorageAt>ethGetStorageAt(java.lang.String address, java.math.BigInteger position, DefaultBlockParameter defaultBlockParameter)Request<?,EthTransaction>ethGetTransactionByBlockHashAndIndex(java.lang.String blockHash, java.math.BigInteger transactionIndex)Request<?,EthTransaction>ethGetTransactionByBlockNumberAndIndex(DefaultBlockParameter defaultBlockParameter, java.math.BigInteger transactionIndex)Request<?,EthTransaction>ethGetTransactionByHash(java.lang.String transactionHash)Request<?,EthGetTransactionCount>ethGetTransactionCount(java.lang.String address, DefaultBlockParameter defaultBlockParameter)Request<?,EthGetTransactionReceipt>ethGetTransactionReceipt(java.lang.String transactionHash)Request<?,EthBlock>ethGetUncleByBlockHashAndIndex(java.lang.String blockHash, java.math.BigInteger transactionIndex)Request<?,EthBlock>ethGetUncleByBlockNumberAndIndex(DefaultBlockParameter defaultBlockParameter, java.math.BigInteger uncleIndex)Request<?,EthGetUncleCountByBlockHash>ethGetUncleCountByBlockHash(java.lang.String blockHash)Request<?,EthGetUncleCountByBlockNumber>ethGetUncleCountByBlockNumber(DefaultBlockParameter defaultBlockParameter)Request<?,EthGetWork>ethGetWork()Request<?,EthHashrate>ethHashrate()io.reactivex.Flowable<Log>ethLogFlowable(EthFilter ethFilter)Create an flowable to filter for specific log events on the blockchain.Request<?,EthMining>ethMining()Request<?,EthFilter>ethNewBlockFilter()Request<?,EthFilter>ethNewFilter(EthFilter ethFilter)Request<?,EthFilter>ethNewPendingTransactionFilter()io.reactivex.Flowable<java.lang.String>ethPendingTransactionHashFlowable()Create an Flowable to emit pending transactions, i.e.Request<?,EthProtocolVersion>ethProtocolVersion()Request<?,EthSendTransaction>ethSendRawTransaction(java.lang.String signedTransactionData)Request<?,EthSendTransaction>ethSendTransaction(Transaction transaction)Request<?,EthSign>ethSign(java.lang.String address, java.lang.String sha3HashOfDataToSign)Request<?,EthSubmitHashrate>ethSubmitHashrate(java.lang.String hashrate, java.lang.String clientId)Request<?,EthSubmitWork>ethSubmitWork(java.lang.String nonce, java.lang.String headerPowHash, java.lang.String mixDigest)Request<?,EthSyncing>ethSyncing()Request<?,EthUninstallFilter>ethUninstallFilter(java.math.BigInteger filterId)io.reactivex.Flowable<LogNotification>logsNotifications(java.util.List<java.lang.String> addresses, java.util.List<java.lang.String> topics)Creates aaFlowableinstance that emits notifications for logs included in new imported blocks.Request<?,NetListening>netListening()Request<?,NetPeerCount>netPeerCount()Request<?,NetVersion>netVersion()BatchRequestnewBatch()Create a newBatchRequest.io.reactivex.Flowable<NewHeadsNotification>newHeadsNotifications()Creates aFlowableinstance that emits a notification when a new header is appended to a chain, including chain reorganizations.io.reactivex.Flowable<Transaction>pendingTransactionFlowable()Create anFlowableinstance to emit all pending transactions that have yet to be placed into a block on the blockchain.io.reactivex.Flowable<EthBlock>replayPastAndFutureBlocksFlowable(DefaultBlockParameter startBlock, boolean fullTransactionObjects)Creates aFlowableinstance that emits all blocks from the requested block number to the most current.io.reactivex.Flowable<Transaction>replayPastAndFutureTransactionsFlowable(DefaultBlockParameter startBlock)As perWeb3jRx.replayPastAndFutureBlocksFlowable(DefaultBlockParameter, boolean), except that all transactions contained within the blocks are emitted.io.reactivex.Flowable<EthBlock>replayPastBlocksFlowable(DefaultBlockParameter startBlock, boolean fullTransactionObjects)Creates aFlowableinstance that emits all blocks from the requested block number to the most current.io.reactivex.Flowable<EthBlock>replayPastBlocksFlowable(DefaultBlockParameter startBlock, boolean fullTransactionObjects, io.reactivex.Flowable<EthBlock> onCompleteFlowable)Create aFlowableinstance that emits all transactions from the blockchain starting with a provided block number.io.reactivex.Flowable<EthBlock>replayPastBlocksFlowable(DefaultBlockParameter startBlock, DefaultBlockParameter endBlock, boolean fullTransactionObjects)Create anFlowableinstance that emits all blocks from the blockchain contained within the requested range.io.reactivex.Flowable<EthBlock>replayPastBlocksFlowable(DefaultBlockParameter startBlock, DefaultBlockParameter endBlock, boolean fullTransactionObjects, boolean ascending)Create anFlowableinstance that emits all blocks from the blockchain contained within the requested range.io.reactivex.Flowable<Transaction>replayPastTransactionsFlowable(DefaultBlockParameter startBlock)Creates aFlowableinstance that emits all transactions from the requested block number to the most current.io.reactivex.Flowable<Transaction>replayPastTransactionsFlowable(DefaultBlockParameter startBlock, DefaultBlockParameter endBlock)Create aFlowableinstance that emits all transactions from the blockchain contained within the requested range.Request<?,ShhAddToGroup>shhAddToGroup(java.lang.String identityAddress)Request<?,ShhMessages>shhGetFilterChanges(java.math.BigInteger filterId)Request<?,ShhMessages>shhGetMessages(java.math.BigInteger filterId)Request<?,ShhHasIdentity>shhHasIdentity(java.lang.String identityAddress)Request<?,ShhNewFilter>shhNewFilter(ShhFilter shhFilter)Request<?,ShhNewGroup>shhNewGroup()Request<?,ShhNewIdentity>shhNewIdentity()Request<?,ShhPost>shhPost(ShhPost shhPost)Request<?,ShhUninstallFilter>shhUninstallFilter(java.math.BigInteger filterId)Request<?,ShhVersion>shhVersion()voidshutdown()Shutdowns a Web3j instance and closes opened resources.io.reactivex.Flowable<Transaction>transactionFlowable()Create anFlowableinstance to emit all new transactions as they are confirmed on the blockchain.Request<?,TxPoolStatus>txPoolStatus()Request<?,Web3ClientVersion>web3ClientVersion()Request<?,Web3Sha3>web3Sha3(java.lang.String data)
-
-
-
Field Detail
-
DEFAULT_BLOCK_TIME
public static final int DEFAULT_BLOCK_TIME
- See Also:
- Constant Field Values
-
web3jService
protected final Web3jService web3jService
-
-
Constructor Detail
-
JsonRpc2_0Web3j
public JsonRpc2_0Web3j(Web3jService web3jService)
-
JsonRpc2_0Web3j
public JsonRpc2_0Web3j(Web3jService web3jService, long pollingInterval, java.util.concurrent.ScheduledExecutorService scheduledExecutorService)
-
-
Method Detail
-
web3ClientVersion
public Request<?,Web3ClientVersion> web3ClientVersion()
- Specified by:
web3ClientVersionin interfaceEthereum
-
netVersion
public Request<?,NetVersion> netVersion()
- Specified by:
netVersionin interfaceEthereum
-
netListening
public Request<?,NetListening> netListening()
- Specified by:
netListeningin interfaceEthereum
-
netPeerCount
public Request<?,NetPeerCount> netPeerCount()
- Specified by:
netPeerCountin interfaceEthereum
-
adminNodeInfo
public Request<?,AdminNodeInfo> adminNodeInfo()
- Specified by:
adminNodeInfoin interfaceEthereum
-
adminPeers
public Request<?,AdminPeers> adminPeers()
- Specified by:
adminPeersin interfaceEthereum
-
adminAddPeer
public Request<?,BooleanResponse> adminAddPeer(java.lang.String url)
- Specified by:
adminAddPeerin interfaceEthereum
-
adminRemovePeer
public Request<?,BooleanResponse> adminRemovePeer(java.lang.String url)
- Specified by:
adminRemovePeerin interfaceEthereum
-
adminDataDir
public Request<?,AdminDataDir> adminDataDir()
- Specified by:
adminDataDirin interfaceEthereum
-
ethProtocolVersion
public Request<?,EthProtocolVersion> ethProtocolVersion()
- Specified by:
ethProtocolVersionin interfaceEthereum
-
ethChainId
public Request<?,EthChainId> ethChainId()
- Specified by:
ethChainIdin interfaceEthereum
-
ethCoinbase
public Request<?,EthCoinbase> ethCoinbase()
- Specified by:
ethCoinbasein interfaceEthereum
-
ethSyncing
public Request<?,EthSyncing> ethSyncing()
- Specified by:
ethSyncingin interfaceEthereum
-
ethHashrate
public Request<?,EthHashrate> ethHashrate()
- Specified by:
ethHashratein interfaceEthereum
-
ethGasPrice
public Request<?,EthGasPrice> ethGasPrice()
- Specified by:
ethGasPricein interfaceEthereum
-
ethAccounts
public Request<?,EthAccounts> ethAccounts()
- Specified by:
ethAccountsin interfaceEthereum
-
ethBlockNumber
public Request<?,EthBlockNumber> ethBlockNumber()
- Specified by:
ethBlockNumberin interfaceEthereum
-
ethGetBalance
public Request<?,EthGetBalance> ethGetBalance(java.lang.String address, DefaultBlockParameter defaultBlockParameter)
- Specified by:
ethGetBalancein interfaceEthereum
-
ethGetStorageAt
public Request<?,EthGetStorageAt> ethGetStorageAt(java.lang.String address, java.math.BigInteger position, DefaultBlockParameter defaultBlockParameter)
- Specified by:
ethGetStorageAtin interfaceEthereum
-
ethGetTransactionCount
public Request<?,EthGetTransactionCount> ethGetTransactionCount(java.lang.String address, DefaultBlockParameter defaultBlockParameter)
- Specified by:
ethGetTransactionCountin interfaceEthereum
-
ethGetBlockTransactionCountByHash
public Request<?,EthGetBlockTransactionCountByHash> ethGetBlockTransactionCountByHash(java.lang.String blockHash)
- Specified by:
ethGetBlockTransactionCountByHashin interfaceEthereum
-
ethGetBlockTransactionCountByNumber
public Request<?,EthGetBlockTransactionCountByNumber> ethGetBlockTransactionCountByNumber(DefaultBlockParameter defaultBlockParameter)
- Specified by:
ethGetBlockTransactionCountByNumberin interfaceEthereum
-
ethGetUncleCountByBlockHash
public Request<?,EthGetUncleCountByBlockHash> ethGetUncleCountByBlockHash(java.lang.String blockHash)
- Specified by:
ethGetUncleCountByBlockHashin interfaceEthereum
-
ethGetUncleCountByBlockNumber
public Request<?,EthGetUncleCountByBlockNumber> ethGetUncleCountByBlockNumber(DefaultBlockParameter defaultBlockParameter)
- Specified by:
ethGetUncleCountByBlockNumberin interfaceEthereum
-
ethGetCode
public Request<?,EthGetCode> ethGetCode(java.lang.String address, DefaultBlockParameter defaultBlockParameter)
- Specified by:
ethGetCodein interfaceEthereum
-
ethSign
public Request<?,EthSign> ethSign(java.lang.String address, java.lang.String sha3HashOfDataToSign)
-
ethSendTransaction
public Request<?,EthSendTransaction> ethSendTransaction(Transaction transaction)
- Specified by:
ethSendTransactionin interfaceEthereum
-
ethSendRawTransaction
public Request<?,EthSendTransaction> ethSendRawTransaction(java.lang.String signedTransactionData)
- Specified by:
ethSendRawTransactionin interfaceEthereum
-
ethCall
public Request<?,EthCall> ethCall(Transaction transaction, DefaultBlockParameter defaultBlockParameter)
-
ethEstimateGas
public Request<?,EthEstimateGas> ethEstimateGas(Transaction transaction)
- Specified by:
ethEstimateGasin interfaceEthereum
-
ethGetBlockByHash
public Request<?,EthBlock> ethGetBlockByHash(java.lang.String blockHash, boolean returnFullTransactionObjects)
- Specified by:
ethGetBlockByHashin interfaceEthereum
-
ethGetBlockByNumber
public Request<?,EthBlock> ethGetBlockByNumber(DefaultBlockParameter defaultBlockParameter, boolean returnFullTransactionObjects)
- Specified by:
ethGetBlockByNumberin interfaceEthereum
-
ethGetTransactionByHash
public Request<?,EthTransaction> ethGetTransactionByHash(java.lang.String transactionHash)
- Specified by:
ethGetTransactionByHashin interfaceEthereum
-
ethGetTransactionByBlockHashAndIndex
public Request<?,EthTransaction> ethGetTransactionByBlockHashAndIndex(java.lang.String blockHash, java.math.BigInteger transactionIndex)
- Specified by:
ethGetTransactionByBlockHashAndIndexin interfaceEthereum
-
ethGetTransactionByBlockNumberAndIndex
public Request<?,EthTransaction> ethGetTransactionByBlockNumberAndIndex(DefaultBlockParameter defaultBlockParameter, java.math.BigInteger transactionIndex)
- Specified by:
ethGetTransactionByBlockNumberAndIndexin interfaceEthereum
-
ethGetTransactionReceipt
public Request<?,EthGetTransactionReceipt> ethGetTransactionReceipt(java.lang.String transactionHash)
- Specified by:
ethGetTransactionReceiptin interfaceEthereum
-
ethGetUncleByBlockHashAndIndex
public Request<?,EthBlock> ethGetUncleByBlockHashAndIndex(java.lang.String blockHash, java.math.BigInteger transactionIndex)
- Specified by:
ethGetUncleByBlockHashAndIndexin interfaceEthereum
-
ethGetUncleByBlockNumberAndIndex
public Request<?,EthBlock> ethGetUncleByBlockNumberAndIndex(DefaultBlockParameter defaultBlockParameter, java.math.BigInteger uncleIndex)
- Specified by:
ethGetUncleByBlockNumberAndIndexin interfaceEthereum
-
ethGetCompilers
public Request<?,EthGetCompilers> ethGetCompilers()
- Specified by:
ethGetCompilersin interfaceEthereum
-
ethCompileLLL
public Request<?,EthCompileLLL> ethCompileLLL(java.lang.String sourceCode)
- Specified by:
ethCompileLLLin interfaceEthereum
-
ethCompileSolidity
public Request<?,EthCompileSolidity> ethCompileSolidity(java.lang.String sourceCode)
- Specified by:
ethCompileSolidityin interfaceEthereum
-
ethCompileSerpent
public Request<?,EthCompileSerpent> ethCompileSerpent(java.lang.String sourceCode)
- Specified by:
ethCompileSerpentin interfaceEthereum
-
ethNewFilter
public Request<?,EthFilter> ethNewFilter(EthFilter ethFilter)
- Specified by:
ethNewFilterin interfaceEthereum
-
ethNewBlockFilter
public Request<?,EthFilter> ethNewBlockFilter()
- Specified by:
ethNewBlockFilterin interfaceEthereum
-
ethNewPendingTransactionFilter
public Request<?,EthFilter> ethNewPendingTransactionFilter()
- Specified by:
ethNewPendingTransactionFilterin interfaceEthereum
-
ethUninstallFilter
public Request<?,EthUninstallFilter> ethUninstallFilter(java.math.BigInteger filterId)
- Specified by:
ethUninstallFilterin interfaceEthereum
-
ethGetFilterChanges
public Request<?,EthLog> ethGetFilterChanges(java.math.BigInteger filterId)
- Specified by:
ethGetFilterChangesin interfaceEthereum
-
ethGetFilterLogs
public Request<?,EthLog> ethGetFilterLogs(java.math.BigInteger filterId)
- Specified by:
ethGetFilterLogsin interfaceEthereum
-
ethGetLogs
public Request<?,EthLog> ethGetLogs(EthFilter ethFilter)
- Specified by:
ethGetLogsin interfaceEthereum
-
ethGetWork
public Request<?,EthGetWork> ethGetWork()
- Specified by:
ethGetWorkin interfaceEthereum
-
ethSubmitWork
public Request<?,EthSubmitWork> ethSubmitWork(java.lang.String nonce, java.lang.String headerPowHash, java.lang.String mixDigest)
- Specified by:
ethSubmitWorkin interfaceEthereum
-
ethSubmitHashrate
public Request<?,EthSubmitHashrate> ethSubmitHashrate(java.lang.String hashrate, java.lang.String clientId)
- Specified by:
ethSubmitHashratein interfaceEthereum
-
dbPutString
public Request<?,DbPutString> dbPutString(java.lang.String databaseName, java.lang.String keyName, java.lang.String stringToStore)
- Specified by:
dbPutStringin interfaceEthereum
-
dbGetString
public Request<?,DbGetString> dbGetString(java.lang.String databaseName, java.lang.String keyName)
- Specified by:
dbGetStringin interfaceEthereum
-
dbPutHex
public Request<?,DbPutHex> dbPutHex(java.lang.String databaseName, java.lang.String keyName, java.lang.String dataToStore)
-
dbGetHex
public Request<?,DbGetHex> dbGetHex(java.lang.String databaseName, java.lang.String keyName)
-
shhVersion
public Request<?,ShhVersion> shhVersion()
- Specified by:
shhVersionin interfaceEthereum
-
shhNewIdentity
public Request<?,ShhNewIdentity> shhNewIdentity()
- Specified by:
shhNewIdentityin interfaceEthereum
-
shhHasIdentity
public Request<?,ShhHasIdentity> shhHasIdentity(java.lang.String identityAddress)
- Specified by:
shhHasIdentityin interfaceEthereum
-
shhNewGroup
public Request<?,ShhNewGroup> shhNewGroup()
- Specified by:
shhNewGroupin interfaceEthereum
-
shhAddToGroup
public Request<?,ShhAddToGroup> shhAddToGroup(java.lang.String identityAddress)
- Specified by:
shhAddToGroupin interfaceEthereum
-
shhNewFilter
public Request<?,ShhNewFilter> shhNewFilter(ShhFilter shhFilter)
- Specified by:
shhNewFilterin interfaceEthereum
-
shhUninstallFilter
public Request<?,ShhUninstallFilter> shhUninstallFilter(java.math.BigInteger filterId)
- Specified by:
shhUninstallFilterin interfaceEthereum
-
shhGetFilterChanges
public Request<?,ShhMessages> shhGetFilterChanges(java.math.BigInteger filterId)
- Specified by:
shhGetFilterChangesin interfaceEthereum
-
shhGetMessages
public Request<?,ShhMessages> shhGetMessages(java.math.BigInteger filterId)
- Specified by:
shhGetMessagesin interfaceEthereum
-
txPoolStatus
public Request<?,TxPoolStatus> txPoolStatus()
- Specified by:
txPoolStatusin interfaceEthereum
-
newHeadsNotifications
public io.reactivex.Flowable<NewHeadsNotification> newHeadsNotifications()
Description copied from interface:Web3jRxCreates aFlowableinstance that emits a notification when a new header is appended to a chain, including chain reorganizations.- Specified by:
newHeadsNotificationsin interfaceWeb3jRx- Returns:
- a
Flowableinstance that emits a notification for every new header
-
logsNotifications
public io.reactivex.Flowable<LogNotification> logsNotifications(java.util.List<java.lang.String> addresses, java.util.List<java.lang.String> topics)
Description copied from interface:Web3jRxCreates aaFlowableinstance that emits notifications for logs included in new imported blocks.- Specified by:
logsNotificationsin interfaceWeb3jRx- Parameters:
addresses- only return logs from this list of address. Return logs from all addresses if the list is emptytopics- only return logs that match specified topics. Returns logs for all topics if the list is empty- Returns:
- a
Flowableinstance that emits logs included in new blocks
-
ethBlockHashFlowable
public io.reactivex.Flowable<java.lang.String> ethBlockHashFlowable()
Description copied from interface:Web3jRxCreate an Flowable to emit block hashes.- Specified by:
ethBlockHashFlowablein interfaceWeb3jRx- Returns:
- a
Flowableinstance that emits all new block hashes as new blocks are created on the blockchain
-
ethPendingTransactionHashFlowable
public io.reactivex.Flowable<java.lang.String> ethPendingTransactionHashFlowable()
Description copied from interface:Web3jRxCreate an Flowable to emit pending transactions, i.e. those transactions that have been submitted by a node, but don't yet form part of a block (haven't been mined yet).- Specified by:
ethPendingTransactionHashFlowablein interfaceWeb3jRx- Returns:
- a
Flowableinstance to emit pending transaction hashes.
-
ethLogFlowable
public io.reactivex.Flowable<Log> ethLogFlowable(EthFilter ethFilter)
Description copied from interface:Web3jRxCreate an flowable to filter for specific log events on the blockchain.- Specified by:
ethLogFlowablein interfaceWeb3jRx- Parameters:
ethFilter- filter criteria- Returns:
- a
Flowableinstance that emits all Log events matching the filter
-
transactionFlowable
public io.reactivex.Flowable<Transaction> transactionFlowable()
Description copied from interface:Web3jRxCreate anFlowableinstance to emit all new transactions as they are confirmed on the blockchain. i.e. they have been mined and are incorporated into a block.- Specified by:
transactionFlowablein interfaceWeb3jRx- Returns:
- a
Flowableinstance to emit new transactions on the blockchain
-
pendingTransactionFlowable
public io.reactivex.Flowable<Transaction> pendingTransactionFlowable()
Description copied from interface:Web3jRxCreate anFlowableinstance to emit all pending transactions that have yet to be placed into a block on the blockchain.- Specified by:
pendingTransactionFlowablein interfaceWeb3jRx- Returns:
- a
Flowableinstance to emit pending transactions
-
blockFlowable
public io.reactivex.Flowable<EthBlock> blockFlowable(boolean fullTransactionObjects)
Description copied from interface:Web3jRxCreate anFlowableinstance that emits newly created blocks on the blockchain.- Specified by:
blockFlowablein interfaceWeb3jRx- Parameters:
fullTransactionObjects- if true, provides transactions embedded in blocks, otherwise transaction hashes- Returns:
- a
Flowableinstance that emits all new blocks as they are added to the blockchain
-
replayPastBlocksFlowable
public io.reactivex.Flowable<EthBlock> replayPastBlocksFlowable(DefaultBlockParameter startBlock, DefaultBlockParameter endBlock, boolean fullTransactionObjects)
Description copied from interface:Web3jRxCreate anFlowableinstance that emits all blocks from the blockchain contained within the requested range.- Specified by:
replayPastBlocksFlowablein interfaceWeb3jRx- Parameters:
startBlock- block number to commence withendBlock- block number to finish withfullTransactionObjects- if true, provides transactions embedded in blocks, otherwise transaction hashes- Returns:
- a
Flowableinstance to emit these blocks
-
replayPastBlocksFlowable
public io.reactivex.Flowable<EthBlock> replayPastBlocksFlowable(DefaultBlockParameter startBlock, DefaultBlockParameter endBlock, boolean fullTransactionObjects, boolean ascending)
Description copied from interface:Web3jRxCreate anFlowableinstance that emits all blocks from the blockchain contained within the requested range.- Specified by:
replayPastBlocksFlowablein interfaceWeb3jRx- Parameters:
startBlock- block number to commence withendBlock- block number to finish withfullTransactionObjects- if true, provides transactions embedded in blocks, otherwise transaction hashesascending- if true, emits blocks in ascending order between range, otherwise in descending order- Returns:
- a
Flowableinstance to emit these blocks
-
replayPastBlocksFlowable
public io.reactivex.Flowable<EthBlock> replayPastBlocksFlowable(DefaultBlockParameter startBlock, boolean fullTransactionObjects, io.reactivex.Flowable<EthBlock> onCompleteFlowable)
Description copied from interface:Web3jRxCreate aFlowableinstance that emits all transactions from the blockchain starting with a provided block number. Once it has replayed up to the most current block, the provided Flowable is invoked.To automatically subscribe to new blocks, use
Web3jRx.replayPastAndFutureBlocksFlowable(DefaultBlockParameter, boolean).- Specified by:
replayPastBlocksFlowablein interfaceWeb3jRx- Parameters:
startBlock- the block number we wish to request fromfullTransactionObjects- if we require fullTransactionobjects to be provided in theEthBlockresponsesonCompleteFlowable- a subsequent Flowable that we wish to run once we are caught up with the latest block- Returns:
- a
Flowableinstance to emit all requested blocks
-
replayPastBlocksFlowable
public io.reactivex.Flowable<EthBlock> replayPastBlocksFlowable(DefaultBlockParameter startBlock, boolean fullTransactionObjects)
Description copied from interface:Web3jRxCreates aFlowableinstance that emits all blocks from the requested block number to the most current. Once it has emitted the most current block, onComplete is called.- Specified by:
replayPastBlocksFlowablein interfaceWeb3jRx- Parameters:
startBlock- the block number we wish to request fromfullTransactionObjects- if we require fullTransactionobjects to be provided in theEthBlockresponses- Returns:
- a
Flowableinstance to emit all requested blocks
-
replayPastTransactionsFlowable
public io.reactivex.Flowable<Transaction> replayPastTransactionsFlowable(DefaultBlockParameter startBlock, DefaultBlockParameter endBlock)
Description copied from interface:Web3jRxCreate aFlowableinstance that emits all transactions from the blockchain contained within the requested range.- Specified by:
replayPastTransactionsFlowablein interfaceWeb3jRx- Parameters:
startBlock- block number to commence withendBlock- block number to finish with- Returns:
- a
Flowableinstance to emit these transactions in the order they appear in the blocks
-
replayPastTransactionsFlowable
public io.reactivex.Flowable<Transaction> replayPastTransactionsFlowable(DefaultBlockParameter startBlock)
Description copied from interface:Web3jRxCreates aFlowableinstance that emits all transactions from the requested block number to the most current. Once it has emitted the most current block's transactions, onComplete is called.- Specified by:
replayPastTransactionsFlowablein interfaceWeb3jRx- Parameters:
startBlock- the block number we wish to request from- Returns:
- a
Flowableinstance to emit all requested transactions
-
replayPastAndFutureBlocksFlowable
public io.reactivex.Flowable<EthBlock> replayPastAndFutureBlocksFlowable(DefaultBlockParameter startBlock, boolean fullTransactionObjects)
Description copied from interface:Web3jRxCreates aFlowableinstance that emits all blocks from the requested block number to the most current. Once it has emitted the most current block, it starts emitting new blocks as they are created.- Specified by:
replayPastAndFutureBlocksFlowablein interfaceWeb3jRx- Parameters:
startBlock- the block number we wish to request fromfullTransactionObjects- if we require fullTransactionobjects to be provided in theEthBlockresponses- Returns:
- a
Flowableinstance to emit all requested blocks and future
-
replayPastAndFutureTransactionsFlowable
public io.reactivex.Flowable<Transaction> replayPastAndFutureTransactionsFlowable(DefaultBlockParameter startBlock)
Description copied from interface:Web3jRxAs perWeb3jRx.replayPastAndFutureBlocksFlowable(DefaultBlockParameter, boolean), except that all transactions contained within the blocks are emitted.- Specified by:
replayPastAndFutureTransactionsFlowablein interfaceWeb3jRx- Parameters:
startBlock- the block number we wish to request from- Returns:
- a
Flowableinstance to emit all requested transactions and future
-
shutdown
public void shutdown()
Description copied from interface:Web3jShutdowns a Web3j instance and closes opened resources.
-
newBatch
public BatchRequest newBatch()
Description copied from interface:BatcherCreate a newBatchRequest.
-
-