作者热门文章
- iOS/Objective-C 元类和类别
- objective-c - -1001 错误,当 NSURLSession 通过 httpproxy 和/etc/hosts
- java - 使用网络类获取 url 地址
- ios - 推送通知中不播放声音
我正在尝试使用 Java API 获取 Aion 中的帐户余额。无论我做什么,我都无法从 account
变量中获取值。
account = "a06f02e986965ddd3398c4de87e3708072ad58d96e9c53e87c31c8c970b211e5";
BigInteger account_balance = api.getChain().getBalance(account).getObject();
System.out.format("%n%s balance is = %d nAmp (over %d AION)%n",
account,
account_balance,
account_balance.divide(BigInteger.TEN.pow(18)));
有人有什么想法吗?
最佳答案
您需要将您的账户地址包裹在Address.wrap
中。
account = Address.wrap("a06f02e9...");
关于java - 显示 Aion 账户的余额,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52838707/
我使用 MERN 堆栈应用程序通过前端将我的 java 合约部署到 Mastery 网络,并在编译时遇到以下错误: Module not found: Error: Can't resolve 'fs
我正在尝试使用 Java API 获取 Aion 中的帐户余额。无论我做什么,我都无法从 account 变量中获取值。 account = "a06f02e986965ddd3398c4de87e3
当用户在网站上创建新帐户时,我希望创建一个 Aion 帐户/地址。我发现的唯一方法是通过 web3 API。有没有办法使用 Java 插件在后端完成此操作? 或者是否有第三方 API 可以促进这一点?
当我使用 Maven 和嵌入式 AVM 调用合约时,我收到以下消息: [ERROR] Failed to execute goal org.aion4j:aion4j-maven-plugin:0.5
我正在尝试将 blocksigner.jar 放入单独的 docker 容器中以进行自动部署 - 但我不断收到此错误: java -jar block_signer.jar -config conf
我是一名优秀的程序员,十分优秀!