public class BitcoinServiceImpl extends Object implements PlatformService<BitcoinTransactionGenerate>
| 构造器和说明 |
|---|
BitcoinServiceImpl(BitcoinProperties properties) |
| 限定符和类型 | 方法和说明 |
|---|---|
BigInteger |
getBalanceByAddressAndContract(String address,
Contract contract) |
Integer |
getDecimalsByContract(Contract contract) |
BigDecimal |
getNumberByBalanceAndContract(BigInteger balance,
Contract contract,
MathContext mathContext) |
Optional<TransactionInfo> |
getTransactionByHash(String hash) |
long |
sleepTime()
休眠时间,如果不允许请求,则手动休眠, 默认5秒
|
TransferResult |
transactionBroadcast(BitcoinTransactionGenerate generate) |
BitcoinTransactionGenerate |
transactionGenerate(Account from,
String to,
Contract contract,
BigDecimal value,
TransferParams params) |
BitcoinTransactionGenerate |
transactionSign(BitcoinTransactionGenerate generate) |
boolean |
validate(String address) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetNumberByAddressAndContract, getNumberByBalanceAndContract, transfer, transfer, valueToBalanceByContractpublic BitcoinServiceImpl(BitcoinProperties properties)
public Optional<TransactionInfo> getTransactionByHash(String hash) throws Exception
getTransactionByHash 在接口中 PlatformService<BitcoinTransactionGenerate>Exceptionpublic Integer getDecimalsByContract(Contract contract) throws com.fasterxml.jackson.core.JsonProcessingException
getDecimalsByContract 在接口中 PlatformService<BitcoinTransactionGenerate>com.fasterxml.jackson.core.JsonProcessingExceptionpublic BigInteger getBalanceByAddressAndContract(String address, Contract contract) throws com.fasterxml.jackson.core.JsonProcessingException
getBalanceByAddressAndContract 在接口中 PlatformService<BitcoinTransactionGenerate>com.fasterxml.jackson.core.JsonProcessingExceptionpublic BigDecimal getNumberByBalanceAndContract(BigInteger balance, Contract contract, MathContext mathContext) throws com.fasterxml.jackson.core.JsonProcessingException
getNumberByBalanceAndContract 在接口中 PlatformService<BitcoinTransactionGenerate>com.fasterxml.jackson.core.JsonProcessingExceptionpublic BitcoinTransactionGenerate transactionGenerate(Account from, String to, Contract contract, BigDecimal value, TransferParams params) throws Exception
transactionGenerate 在接口中 PlatformService<BitcoinTransactionGenerate>Exceptionpublic BitcoinTransactionGenerate transactionSign(BitcoinTransactionGenerate generate) throws org.bitcoinj.core.SignatureDecodeException
transactionSign 在接口中 PlatformService<BitcoinTransactionGenerate>org.bitcoinj.core.SignatureDecodeExceptionpublic TransferResult transactionBroadcast(BitcoinTransactionGenerate generate) throws Exception
transactionBroadcast 在接口中 PlatformService<BitcoinTransactionGenerate>Exceptionpublic boolean validate(String address)
validate 在接口中 PlatformService<BitcoinTransactionGenerate>public long sleepTime()
Copyright © 2021. All rights reserved.