public interface EthereumConnection extends javax.resource.cci.Connection, AutoCloseable
Modifier and Type | Method and Description |
---|---|
org.web3j.protocol.core.methods.response.TransactionReceipt |
deploy(Class<? extends org.web3j.tx.Contract> contractClass,
org.web3j.tx.gas.ContractGasProvider contractGasProvider,
org.web3j.crypto.Credentials credentials,
Long chainId)
Deploys a given contract.
|
org.web3j.protocol.core.methods.response.Transaction |
findTransaction(String transactionHash)
Gives back the transaction for a given transaction hash.
|
List<String> |
getAccounts()
Gives back a list of all accounts managed by the client node.
|
BigInteger |
getBalance(String address)
Gives back the balance for the address.
|
org.web3j.protocol.core.methods.response.EthBlock.Block |
getBlock(org.web3j.protocol.core.DefaultBlockParameter defaultBlockParameter,
boolean fullTransactions)
Gives back a block for the given block number.
|
org.web3j.protocol.core.methods.response.EthBlock.Block |
getBlock(String blockHash,
boolean fullTransactions)
Gives back a block for the given block hash.
|
BigInteger |
getBlockNumber()
Gives back the latest block number.
|
Long |
getChainId()
Retrieve the chain identifier of the Ethereum network.
|
String |
getClientVersion()
Gives back the web3 client version.
|
BigInteger |
getGasPrice()
Gives back the node gas price.
|
BigInteger |
getMaxPriorityFeePerGas()
Gives back the node estimate for maximum priority fee per gas.
|
String |
getNetVersion()
Gives back the net version.
|
BigInteger |
getPeerCount()
Gives back the peer count of the Ethereum client node.
|
TransactionConfirmation |
getTransactionConfirmation(String transactionHash)
Gives back the status of a transaction.
|
BigInteger |
getTransactionCount(String address)
Gives back the transaction nonce for the given address.
|
org.web3j.protocol.core.methods.response.EthGetTransactionReceipt |
getTransactionReceipt(String transactionHash)
Gives back the web3 transaction receipt.
|
boolean |
isSyncing()
Returns true if the Ethereum client node is synchronizing.
|
<T extends org.web3j.tx.Contract> |
load(Class<T> contractClass,
String contractAddress,
org.web3j.crypto.Credentials credentials,
Long chainId,
org.web3j.tx.gas.ContractGasProvider contractGasProvider)
Loads a contract.
|
String |
sendAccountTransaction(String account,
String to,
BigInteger value,
BigInteger gasPrice,
BigInteger nonce)
Send transaction via client node account.
|
String |
sendRawTransaction(String rawTransaction)
Sends a raw transaction.
|
String |
sendTransaction(org.web3j.crypto.Credentials credentials,
String to,
BigInteger value,
BigInteger maxFeePerGas,
BigInteger maxPriorityFeePerGas,
Long chainId)
Sends an Ethereum EIP-1559 transaction.
|
String |
sendTransaction(org.web3j.crypto.Credentials credentials,
String to,
BigInteger value,
BigInteger gasPrice,
Long chainId)
Sends an Ethereum transaction.
|
close, createInteraction, getLocalTransaction, getMetaData, getResultSetInfo
close
BigInteger getGasPrice() throws javax.resource.ResourceException
javax.resource.ResourceException
BigInteger getMaxPriorityFeePerGas() throws javax.resource.ResourceException
javax.resource.ResourceException
BigInteger getBlockNumber() throws javax.resource.ResourceException
javax.resource.ResourceException
String sendRawTransaction(String rawTransaction) throws javax.resource.ResourceException, EthereumException
rawTransaction
- javax.resource.ResourceException
EthereumException
TransactionConfirmation getTransactionConfirmation(String transactionHash) throws javax.resource.ResourceException
transactionHash
- javax.resource.ResourceException
org.web3j.protocol.core.methods.response.Transaction findTransaction(String transactionHash) throws javax.resource.ResourceException
transactionHash
- javax.resource.ResourceException
org.web3j.protocol.core.methods.response.EthBlock.Block getBlock(String blockHash, boolean fullTransactions) throws javax.resource.ResourceException
blockHash
- fullTransactions
- javax.resource.ResourceException
org.web3j.protocol.core.methods.response.EthBlock.Block getBlock(org.web3j.protocol.core.DefaultBlockParameter defaultBlockParameter, boolean fullTransactions) throws javax.resource.ResourceException
defaultBlockParameter
- fullTransactions
- javax.resource.ResourceException
BigInteger getBalance(String address) throws javax.resource.ResourceException
address
- javax.resource.ResourceException
BigInteger getTransactionCount(String address) throws javax.resource.ResourceException
address
- javax.resource.ResourceException
List<String> getAccounts() throws javax.resource.ResourceException
javax.resource.ResourceException
String sendAccountTransaction(String account, String to, BigInteger value, BigInteger gasPrice, BigInteger nonce) throws javax.resource.ResourceException, EthereumException
account
- to
- value
- gasPrice
- nonce
- javax.resource.ResourceException
EthereumException
org.web3j.protocol.core.methods.response.TransactionReceipt deploy(Class<? extends org.web3j.tx.Contract> contractClass, org.web3j.tx.gas.ContractGasProvider contractGasProvider, org.web3j.crypto.Credentials credentials, Long chainId) throws javax.resource.ResourceException, EthereumException
contractClass
- contractGasProvider
- credentials
- chainId
- javax.resource.ResourceException
EthereumException
<T extends org.web3j.tx.Contract> T load(Class<T> contractClass, String contractAddress, org.web3j.crypto.Credentials credentials, Long chainId, org.web3j.tx.gas.ContractGasProvider contractGasProvider) throws javax.resource.ResourceException
T
- contractClass
- contractAddress
- credentials
- chainId
- contractGasProvider
- javax.resource.ResourceException
Long getChainId() throws javax.resource.ResourceException, EthereumException
javax.resource.ResourceException
EthereumException
String sendTransaction(org.web3j.crypto.Credentials credentials, String to, BigInteger value, BigInteger gasPrice, Long chainId) throws javax.resource.ResourceException, EthereumException
credentials
- to
- value
- gasPrice
- chainId
- javax.resource.ResourceException
EthereumException
String sendTransaction(org.web3j.crypto.Credentials credentials, String to, BigInteger value, BigInteger maxFeePerGas, BigInteger maxPriorityFeePerGas, Long chainId) throws javax.resource.ResourceException, EthereumException
credentials
- to
- value
- maxFeePerGas
- maxPriorityFeePerGas
- chainId
- javax.resource.ResourceException
EthereumException
String getNetVersion() throws javax.resource.ResourceException
javax.resource.ResourceException
BigInteger getPeerCount() throws javax.resource.ResourceException
javax.resource.ResourceException
boolean isSyncing() throws javax.resource.ResourceException
javax.resource.ResourceException
String getClientVersion() throws javax.resource.ResourceException
javax.resource.ResourceException
org.web3j.protocol.core.methods.response.EthGetTransactionReceipt getTransactionReceipt(String transactionHash) throws javax.resource.ResourceException
transactionHash
- javax.resource.ResourceException
Copyright © 2018–2024 e-Contract.be BV. All rights reserved.