org.bitcoinj.core.Address.toBase58()方法的使用及代码示例

x33g5p2x  于2022-01-16 转载在 其他  
字(2.2k)|赞(0)|评价(0)|浏览(224)

本文整理了Java中org.bitcoinj.core.Address.toBase58()方法的一些代码示例,展示了Address.toBase58()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Address.toBase58()方法的具体详情如下:
包路径:org.bitcoinj.core.Address
类名称:Address
方法名:toBase58

Address.toBase58介绍

暂无

代码示例

代码示例来源:origin: ICOnator/ICOnator-backend

@Override
protected boolean isAddressMonitored(String receivingAddress) {
  return wallet.getWatchedAddresses().stream().anyMatch(
      a -> a.toBase58().contentEquals(receivingAddress));
}

代码示例来源:origin: ICOnator/ICOnator-backend

@Override
public String getReceivingAddress() throws MissingTransactionInformationException {
  try {
    return bitcoinjTxOutput
        .getAddressFromP2PKHScript(this.bitcoinjNetworkParameters)
        .toBase58();
  } catch (Exception e) {
    throw new MissingTransactionInformationException("Couldn't fetch receiving address.", e);
  }
}

代码示例来源:origin: thinkmobiles/BitcoinJ-Wallet-Sample-Android

@Override
public void getInfoDialog() {
  view.displayInfoDialog(walletAppKit.wallet().currentReceiveAddress().toBase58());
}

代码示例来源:origin: thinkmobiles/BitcoinJ-Wallet-Sample-Android

@Override
public void refresh() {
  String myAddress = walletAppKit.wallet().freshReceiveAddress().toBase58();
  view.displayMyBalance(walletAppKit.wallet().getBalance().toFriendlyString());
  view.displayMyAddress(myAddress);
}

代码示例来源:origin: greenaddress/GreenBits

@Test
public void roundtripBase58() throws Exception {
  String base58 = "17kzeh4N8g49GFvdDzSf8PjaPfyoD1MndL";
  assertEquals(base58, Address.fromBase58(null, base58).toBase58());
}

代码示例来源:origin: blockchain/unused-My-Wallet-V3-jar

public static LegacyAddress fromECKey(ECKey ecKey) throws Exception {
  LegacyAddress legacyAddress = new LegacyAddress();
  legacyAddress.setPrivateKeyFromBytes(ecKey.getPrivKeyBytes());
  legacyAddress.setAddress(ecKey.toAddress(PersistentUrls.getInstance().getCurrentNetworkParams()).toBase58());
  legacyAddress.setCreatedDeviceName(BlockchainFramework.getDevice());
  legacyAddress.setCreatedTime(System.currentTimeMillis());
  legacyAddress.setCreatedDeviceVersion(BlockchainFramework.getAppVersion());
  return legacyAddress;
}

代码示例来源:origin: network.quant/overledger-sdk-bitcoin

.uri(
    url,
    bitcoinAccount.getKey().toAddress(bitcoinAccount.getNetworkParameters()).toBase58(),
    BTC_IN_SATOSHI.multiply(BigDecimal.ONE)

相关文章