Update 17_2_App-getinfo.java

This commit is contained in:
Shannon Appelcline 2020-09-02 12:04:58 -10:00 committed by GitHub
parent 297bbe9212
commit 3c15a7d869
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -11,8 +11,7 @@ public class App
public static void main( String[] args ) throws Exception public static void main( String[] args ) throws Exception
{ {
BitcoindRpcClient rpcClient = new BitcoinJSONRPCClient("http://StandUp:6 BitcoindRpcClient rpcClient = new BitcoinJSONRPCClient("http://StandUp:6305f1b2dbb3bc5a16cd0f4aac7e1eba@localhost:18332");
305f1b2dbb3bc5a16cd0f4aac7e1eba@localhost:18332");
MiningInfo info = rpcClient.getMiningInfo(); MiningInfo info = rpcClient.getMiningInfo();
System.out.println("Mining Information"); System.out.println("Mining Information");
@ -27,10 +26,11 @@ public class App
AddressInfo addr1Info = rpcClient.getAddressInfo(addr1); AddressInfo addr1Info = rpcClient.getAddressInfo(addr1);
System.out.println("Address: " + addr1Info.address()); System.out.println("Address: " + addr1Info.address());
System.out.println("MasterFingerPrint: " + addr1Info.hdMasterFingerprint System.out.println("MasterFingerPrint: " + addr1Info.hdMasterFingerprint());
());
System.out.println("HdKeyPath: " + addr1Info.hdKeyPath()); System.out.println("HdKeyPath: " + addr1Info.hdKeyPath());
System.out.println("PubKey: " + addr1Info.pubKey()); System.out.println("PubKey: " + addr1Info.pubKey());
System.out.println("Balance: " + rpcClient.getBalance());
} }
} }