import org.web3j.protocol.Web3j; import org.web3j.protocol.core.methods.response.Web3ClientVersion; import org.web3j.protocol.http.HttpService; public class Web3jExample { public static void main(String[] args) { Web3j web3j = Web3j.build(new HttpService("http://localhost:8545")); try { Web3ClientVersion clientVersion = web3j.web3ClientVersion().send(); String version = clientVersion.getWeb3ClientVersion(); } catch (Exception e) { e.printStackTrace(); } } }


上一篇:
下一篇:
切换中文