import org.web3j.protocol.Web3j; import org.web3j.protocol.http.HttpService; import org.web3j.protocol.core.methods.response.EthBlock; import io.reactivex.Flowable; public class Web3jExample { public static void main(String[] args) { Web3j web3j = Web3j.build(new HttpService("http://localhost:8545")); web3j.blockFlowable(false).subscribe((EthBlock.Block block) -> { }, Throwable::printStackTrace); Flowable.never().blockingSubscribe(); } }


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