Exemplo n.º 1
0
 public DeterministicKey findKeyFromPubKey(byte[] pubkey) {
   lock.lock();
   try {
     return (DeterministicKey) basicKeyChain.findKeyFromPubKey(pubkey);
   } finally {
     lock.unlock();
   }
 }
Exemplo n.º 2
0
 /**
  * Mark the DeterministicKeys as used, if they match the pubkey See {@link
  * com.google.bitcoin.wallet.DeterministicKeyChain#markKeyAsUsed(DeterministicKey)} for more info
  * on this.
  */
 @Nullable
 public DeterministicKey markPubKeyAsUsed(byte[] pubkey) {
   lock.lock();
   try {
     DeterministicKey k = (DeterministicKey) basicKeyChain.findKeyFromPubKey(pubkey);
     if (k != null) markKeyAsUsed(k);
     return k;
   } finally {
     lock.unlock();
   }
 }