diff --git a/src/main/java/com/sparrowwallet/drongo/wallet/Wallet.java b/src/main/java/com/sparrowwallet/drongo/wallet/Wallet.java index d69755f..a034dce 100644 --- a/src/main/java/com/sparrowwallet/drongo/wallet/Wallet.java +++ b/src/main/java/com/sparrowwallet/drongo/wallet/Wallet.java @@ -740,6 +740,17 @@ public class Wallet extends Persistable implements Comparable { } } + public void derivePublicKeys() { + for(KeyPurpose keyPurpose : KeyPurpose.DEFAULT_PURPOSES) { + WalletNode purposeNode = getNode(keyPurpose); + for(WalletNode addressNode : purposeNode.getChildren()) { + for(Keystore keystore : getKeystores()) { + keystore.getPubKey(addressNode); + } + } + } + } + public boolean isWalletTxo(TransactionInput txInput) { return getWalletTxos().keySet().stream().anyMatch(ref -> ref.getHash().equals(txInput.getOutpoint().getHash()) && ref.getIndex() == txInput.getOutpoint().getIndex()); }